File tree Expand file tree Collapse file tree
docs-site/src/content/docs/plugins-detail Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -121,6 +121,32 @@ The `git add` hook applies layered protection:
121121 modified files are included, approval is
122122 required.
123123
124+ ### Temporarily Allowing Staging & Commits
125+
126+ When you're in a workflow where you trust the agent
127+ to stage modified files and commit, you can
128+ temporarily disable the approval prompts using a
129+ ` >allow-git ` trigger. Type it directly at the prompt:
130+
131+ | Trigger | Effect |
132+ | ---------| --------|
133+ | ` >allow-git ` | Allow both staging and commits |
134+ | ` >allow-git staging ` | Allow only staging modified files |
135+ | ` >allow-git commit ` | Allow only commits |
136+ | ` >allow-git off ` | Restore approval prompts |
137+ | ` >allow-git status ` | Show current state |
138+
139+ This is ** session-scoped** — it only affects the
140+ current Claude Code session. Other concurrent sessions
141+ are unaffected, and the allowance is automatically
142+ gone when the session ends.
143+
144+ :::caution
145+ Dangerous operations like ` git add -A ` , ` git add . ` ,
146+ and ` git checkout --force ` remain ** always blocked**
147+ regardless of this setting.
148+ :::
149+
124150### Environment File Protection
125151
126152All operations on ` .env ` files are blocked:
You can’t perform that action at this time.
0 commit comments