23 November 2026
أوقف تشغيل ملفات الـ shell قبل موافقتك على أول أمر في Claude CodeStop shell startup files running before Claude Code approval
You will learn when Claude Code can run your shell startup files before you approve the first command, and how to turn that off with one variable.
Who this guide is for
Developers and team leads who run Claude Code on their own machines and care what runs before they approve.
Key terms
- Shell startup files
- Files like .zshrc and .bashrc that your shell reads every time it starts. They often hold paths and commands you or your tools added.
- Head start
- Preparation that happens before approval: Claude Code can run your shell startup files while it writes the first Bash command of a session, before the permission prompt appears.
- Permission prompt
- The message where Claude Code asks whether it may run a command.
- Environment variable
- A name and a value a program reads at launch. Here the name is CLAUDE_CODE_DISABLE_SHELL_HEAD_START and the value is 1.
The rest is locked
5 full steps, with the ready prompts and the takeaway
Secure, encrypted payment via Stripe
Bought this before? Restore your access
Your access is tied to your email. Enter it here and the content opens right away, any time, on any device
Most value
Start building with me now
We sit together, break down your problem, and I build the AI solution with you step by step
60minutes
- A private session with you
- Real building during the session
- Results you take with you when we finish
100% free
A free consultation about your problem
