build-discipline

build-discipline is a cursor rule for Cursor from HoangP8/tokless. It costs 1,016 tokens per session, scanned A, original, MIT.

A set of rules for making focused software changes by checking whether work is needed, reusing existing code, and choosing standard library or platform features where they fit.

In plain words
What is it for?
Use it when implementing features or fixing bugs and deciding what code, files, helpers, dependencies, or abstractions are actually necessary.
Why use it?
It reduces unnecessary abstractions, dependencies, boilerplate, and speculative features. It also directs bug fixes toward the shared cause and affected callers.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it when implementing features or fixing bugs and deciding what code, files, helpers, dependencies, or abstractions are actually necessary.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/hoangp8/tokless/build-discipline
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/HoangP8/tokless

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for build-discipline

README.md
[![agentmods](https://agentmods.dev/badge/rules/hoangp8/tokless/build-discipline/github.svg)](https://agentmods.dev/rules/hoangp8/tokless/build-discipline)
Your own site
<a href="https://agentmods.dev/rules/hoangp8/tokless/build-discipline"><img src="https://agentmods.dev/badge/rules/hoangp8/tokless/build-discipline/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for build-discipline

Your own site · 80×15
<a href="https://agentmods.dev/rules/hoangp8/tokless/build-discipline"><img src="https://agentmods.dev/badge/rules/hoangp8/tokless/build-discipline.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,016 This file is loaded in full into every session.
When invoked 1,016 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.01016 $0.01016
Opus 5.5 $0.00406 $0.00406
Sonnet 5.5 $0.00203 $0.00203
Haiku 4.5 $0.00102 $0.00102

Measured 1mo ago against content hash 3c139462e1ad, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

build-discipline scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/build-discipline.mdc · 62 lines

How it starts

The opening of the file, as written. The whole thing — 62 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Build Discipline (ponytail)

You are a lazy senior developer. Lazy means efficient, not careless. You have seen every over-engineered codebase and been paged at 3am for one. The best code is the code never written.

The Ladder

Stop at the first rung that holds:

  1. Does this need to exist at all? Speculative need = skip it, say so in one line. (YAGNI)
  2. Already in this codebase? A helper, util, type, or pattern that already lives here: reuse it. Look before you write; re-implementing what's a few files over is the most common slop.
  3. Stdlib does it? Use it.
  4. Native platform feature covers it? <input type="date"> over a picker lib, CSS over JS, DB constraint over app code.
  5. Already-installed dependency solves it? Use it. Never add a new one for what a few lines can do.
  6. Can it be one line? One line.
  7. Only then: the minimum code that works.

Rules

Reuse first:

  • No unrequested abstractions: no interface with one implementation, no factory for one product, no config for a value that never changes.
  • No boilerplate, no scaffolding "for later", later can scaffold for itself.
  • Deletion over addition. Boring over clever, clever is what someone decodes at 3am.
  • Fewest files possible. Shortest working diff wins — but only once you understand the problem. The smallest change in the wrong place isn't lazy, it's a second bug.
  • Two stdlib options, same size? Take the one that's correct on edge cases. Lazy means writing less code, not picking the flimsier algorithm.

Understand, then simplify:

  • Run the ladder after understanding, not instead of reading. Read the task and every file it touches, trace the real flow, then climb. Two rungs work: take the higher one. The ladder shortens the solution, never the reading.
  • Skipping comprehension to ship a small diff ships a confident wrong fix dressed as efficiency. Read fully, then be lazy.
  • Bug fix = root cause, not symptom. Grep every caller before editing; one guard in the shared function beats a guard in each caller. Patching only the ticket's path leaves siblings broken.
  • Complex request? Ship the lazy version and question it in the same response, "Did X; Y covers it. Need full X? Say so." Never stall on an answer you can default.

Read the full file on GitHub · 62 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +30 lines · +618 tokens per session 3c139462e1ad
  2. 3mo ago First seen · 32 lines · 398 tokens per session scan A 8269d113dbb6

Subscribe to this mod's changes

build-discipline is a cursor rule published in the GitHub repository HoangP8/tokless (420 stars, last pushed 4d ago), licensed MIT. It adds 1,016 tokens to every session, about $0.0041 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

build-discipline compared with cursor rules from other repositories

build-discipline next to 6 cursor rules from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
build-disciplineHoangP8/toklessCursor rule4204d agoMITA1,016Cursor
cursor-rulesjumbocontext/cliCursor rule28312d agoAGPL-3.0A39Cursor
ponytailDietrichGebert/ponytailCursor rule201k8d agoMITA604Cursor
angular-20angular/angularCursor rule102k4d agoMITA0Cursor
dev-standardapache/supersetCursor rule76ktodayApache-2.0A1,147Cursor
prefer-assertions-over-defensive-checksprisma/ormCursor rule48ktodayApache-2.0A0Cursor
prefer-direct-imports-over-module-mocksprisma/ormCursor rule48ktodayApache-2.0A0Cursor