cd /news/developer-tools/claude-shortcuts Β· home β€Ί topics β€Ί developer-tools β€Ί article
[ARTICLE Β· art-56262] src=dev.to β†— pub= topic=developer-tools verified=true sentiment=Β· neutral

Claude Shortcuts !

An engineer compiled a cheat sheet of Claude Code CLI flags, covering automation, permissions, cost control, workspace management, session handling, and prompt customization. The flags enable non-interactive scripting, strict output validation, tool permissions, financial circuit breakers, and session forking.

read2 min views1 publishedJul 12, 2026

#

πŸš€ Automation & Scripting

  • -p / --print: Non-interactive mode. Runs a query, outputs the result to stdout, and terminates immediately (essential for CI/CD).
  • --output-format : Formats Claude's responses, enabling structured JSON parsing using tools like jq.
  • --json-schema : Strict output validation. Compels Claude to respond using a specific, predefined JSON structure (only works with -p).
  • --bare: Minimal start mode. Bypasses MCP servers, plugins, hooks, and CLAUDE.md to optimize launch times for scripting tasks. [4, 5, 6, 7, 8]

#

πŸ”’ Permissions & Security

- --permission-mode : Sets the target initial session layer (default, plan, acceptEdits, bypassPermissions).
- --allowedTools / --allowed-tools: Declares specific tools (like Read or Bash) that Claude can run automatically without prompting for manual approval.
  • --disallowedTools: Completely strips specified tools out of Claude's runtime environment.

  • --dangerously-skip-permissions: Completely turns off all confirmation prompts for tool executions. [4, 5, 9, 10]

#

⏱️ Cost Control & Safety Caps

- --max-turns : Defines an upper ceiling for multi-step agentic execution loops to prevent runaway token spend.
- --max-budget-usd : Sets a strict financial circuit breaker by capping the session's overall API dollar cost. [3, 5, 6, 11]

#

πŸ“ Workspace & Context

  • --add-dir : Integrates secondary directories into Claude’s execution space so it can read and update external code.

  • -w / --worktree: Instructs Claude to open and execute inside an isolated git worktree, keeping your main branch clean. [4, 6, 9, 12]

#

πŸ’¬ Session Management

  • -c / --continue: Picks up right where you left off in the directory's most recent conversation thread.
- -r / --resume : Re-opens an exact target historic thread using its specific Session UUID or name.
- --fork-session: Branches an active historical context into a fresh, distinct session ID without altering your past logs. [5, 7, 13]

#

πŸ“ Prompt Customization

- --system-prompt : Fully replaces Claude Code's stock system rules with your own string.
- --append-system-prompt : Appends specialized custom formatting or architecture constraints seamlessly onto the existing system instructions. [5, 7]

[1] [https://x.com](https://x.com/_avichawla/status/2073327425711460834)

[2] [https://shipyard.build](https://shipyard.build/blog/claude-code-cheat-sheet/)

[3] [https://www.linkedin.com](https://www.linkedin.com/posts/vamsipenmetsa_claude-code-has-20-cli-flags-most-engineers-activity-7477298683571728384-Albo)

[4] [https://code.claude.com](https://code.claude.com/docs/en/cli-reference)

[5] [https://github.com](https://github.com/shanraisshan/claude-code-best-practice/blob/main/best-practice/claude-cli-startup-flags.md)

[6] [https://www.gravitee.io](https://www.gravitee.io/blog/claude-code-cli-documentation-commands-flags-and-governance)

[7] [https://www.mager.co](https://www.mager.co/blog/2026-04-20-claude-code-cli-flags/)

[8] [https://codingnomads.com](https://codingnomads.com/claude-code-cli-commands-flags-reference)

[9] [https://phosailabs.com](https://phosailabs.com/blog/claude-code-cli-commands-guide)

[10] [https://www.gravitee.io](https://www.gravitee.io/blog/claude-code-cli-documentation-commands-flags-and-governance)

[11] [https://codingnomads.com](https://codingnomads.com/claude-code-cli-commands-flags-reference)

[12] [https://timdietrich.me](https://timdietrich.me/blog/claude-code-commands-guide/)

[13] [https://github.com](https://github.com/shanraisshan/claude-code-best-practice/blob/main/best-practice/claude-cli-startup-flags.md)
── more in #developer-tools 4 stories Β· sorted by recency
── more on @claude code 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain β€” perfect for shipping the agent you just read about.

$git push zahid main
β†’ Live at https://your-agent.zahid.host βœ“
Get free account β†’ Pricing
from €0/mo Β· no card required
LIVE [news/claude-shortcuts] indexed:0 read:2min 2026-07-12 Β· β€”