Repository navigation
chore(claude): ask before pushes, GitHub API writes and cluster installs - #702
Merged
Merged
Conversation
The shared Claude Code allowlist let an agent run some commands without a prompt that are hard to undo or reach outside the machine: - `git push:*` also matched force pushes. - `gh api:*` matched any API call, including DELETE and POST, and `gh pr:*` matched creating, merging and closing PRs. - `git checkout:*` matched `git checkout -- <file>`, which discards uncommitted work. - `npm install:*` runs package install scripts and can change the lockfile. - `make:*` matched `make helm-install`, `helm-upgrade` and `helm-uninstall` against the current kube context. These now ask first (an `ask` rule wins over an `allow` rule). The allowlist gets the safe forms instead: `npm ci`, `git switch`, and `gh pr view`, `list` and `checks`. Builds, tests, lint and local commits still run without a prompt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The shared Claude Code allowlist (
.claude/settings.json) let an agent run some commands without a prompt that are hard to undo or that reach outside the machine. These now ask first. Builds, tests, lint and local commits still run without a prompt.git push:*gh api:*DELETEandPOSTgh pr:*view,listandchecksallowed;create,mergeandcloseaskgit checkout:*git checkout -- <file>discards uncommitted workgit switchnpm install:*npm ciallowed;npm installasksmake:*make helm-install,helm-upgradeandhelm-uninstallagainst the current kube contextAn
askrule wins over anallowrule, somake helm-installasks even thoughmake:*stays allowed.Personal additions, such as more read-only commands, belong in
.claude/settings.local.json, which is not committed.🤖 Generated with Claude Code