Fetching latest headlinesโ€ฆ
The commands section is the highest-ROI part of your AGENTS.md
NORTH AMERICA
๐Ÿ‡บ๐Ÿ‡ธ United Statesโ€ขJuly 2, 2026

The commands section is the highest-ROI part of your AGENTS.md

0 views0 likes0 comments
Originally published byDev.to

Why commands matter most

Most agent tasks end in a build or a test. List the exact commands and the agent runs them, reads the output, and fixes its own errors before finishing. Leave them out and it guesses โ€” or reports success on code that never passed.

Be literal

"Run the tests" can't be executed. pnpm test can.

## Commands
Install:    pnpm install --frozen-lockfile
Dev:        pnpm dev
Build:      pnpm build
Test (all): pnpm test
Test (one): pnpm test -- path/to/file.test.ts
Typecheck:  pnpm typecheck
Lint + fix: pnpm lint --fix

Don't skip the single-test command

Test (one) lets the agent iterate in seconds on a focused change instead of running the whole suite (or skipping verification entirely).

Name the gate

Say what must pass before a change is "done" โ€” types, lint, tests. The agent treats that as the bar to clear. Bonus: make it match your CI so the work it considers done is work that actually merges.

Monorepo?

Put workspace-wide commands at the root and package-specific ones in each package's AGENTS.md โ€” the nearest file wins.

Free cheat sheet: the format, an annotated example, and the one-line test โ€” AGENTS.md Cheat Sheet.

Go deeper: the full reference โ€” cross-tool setup, the monorepo hierarchy, and a 30-day plan โ€” AGENTS.md: The Complete Guide to the Cross-Tool Agent Standard.

What's in your commands section that's saved you the most rework? ๐Ÿ‘‡

Comments (0)

Sign in to join the discussion

Be the first to comment!