-
-
Notifications
You must be signed in to change notification settings - Fork 0
chore: add Claude settings example file #58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,143 @@ | ||||||
| { | ||||||
| "permissions": { | ||||||
| "allow": [ | ||||||
| "Bash(ls:*)", | ||||||
| "Bash(dir:*)", | ||||||
| "Bash(cd:*)", | ||||||
| "Bash(pwd:*)", | ||||||
| "Bash(cat:*)", | ||||||
| "Bash(head:*)", | ||||||
| "Bash(tail:*)", | ||||||
| "Bash(less:*)", | ||||||
| "Bash(more:*)", | ||||||
| "Bash(echo:*)", | ||||||
| "Bash(printf:*)", | ||||||
| "Bash(which:*)", | ||||||
| "Bash(where:*)", | ||||||
| "Bash(grep:*)", | ||||||
| "Bash(rg:*)", | ||||||
| "Bash(find:*)", | ||||||
| "Bash(findstr:*)", | ||||||
| "Bash(awk:*)", | ||||||
| "Bash(sed:*)", | ||||||
| "Bash(sort:*)", | ||||||
| "Bash(uniq:*)", | ||||||
| "Bash(wc:*)", | ||||||
| "Bash(test:*)", | ||||||
| "Bash([:*)", | ||||||
| "Bash(mkdir:*)", | ||||||
| "Bash(touch:*)", | ||||||
| "Bash(cp:*)", | ||||||
| "Bash(copy:*)", | ||||||
| "Bash(mv:*)", | ||||||
| "Bash(move:*)", | ||||||
| "Bash(git status:*)", | ||||||
| "Bash(git diff:*)", | ||||||
| "Bash(git log:*)", | ||||||
| "Bash(git show:*)", | ||||||
| "Bash(git branch:*)", | ||||||
| "Bash(git ls-files:*)", | ||||||
| "Bash(git ls-tree:*)", | ||||||
| "Bash(git rev-parse:*)", | ||||||
| "Bash(git remote:*)", | ||||||
| "Bash(git fetch:*)", | ||||||
| "Bash(git checkout:*)", | ||||||
| "Bash(git add:*)", | ||||||
| "Bash(git commit:*)", | ||||||
| "Bash(git push:*)", | ||||||
| "Bash(git stash:*)", | ||||||
| "Bash(git stash drop:*)", | ||||||
| "Bash(git stash pop:*)", | ||||||
| "Bash(git rm:*)", | ||||||
| "Bash(git mv:*)", | ||||||
| "Bash(git worktree list:*)", | ||||||
| "Bash(git worktree prune:*)", | ||||||
| "Bash(git describe:*)", | ||||||
| "Bash(git tag:*)", | ||||||
| "Bash(git -C:*)", | ||||||
| "Bash(dotnet:*)", | ||||||
|
||||||
| "Bash(dotnet:*)", |
Copilot
AI
Dec 31, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'git clean' command appears in both the allow list (line 63 as 'dotnet clean') and the deny list (line 99). However, these are actually two different commands: 'dotnet clean' (a safe .NET build cleanup command) and 'git clean' (which can delete untracked files). While they don't technically conflict, this could cause confusion. Consider adding a comment to clarify that 'dotnet clean' is allowed but 'git clean' is denied.
Copilot
AI
Dec 31, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PowerShell and pwsh permissions (lines 67-68) are catch-all patterns that would allow execution of any PowerShell scripts or commands. This is overly permissive and could allow potentially dangerous operations. Consider either removing these entries or adding specific PowerShell commands that should be allowed, similar to how git and dotnet commands are handled.
| "Bash(powershell:*)", | |
| "Bash(pwsh:*)", |
Copilot
AI
Dec 31, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'gh api' permission appears twice with different scoping. Line 130 has 'Bash(gh api:)' in the ask list (requiring user confirmation), while lines 81-82 have specific 'gh api repos//pulls//comments' patterns in the allow list (permitted without confirmation). The more specific patterns on lines 81-82 would be overridden by the broader 'gh api:' pattern in the ask list, potentially allowing unintended access to other API endpoints. Consider removing the catch-all from the ask list to ensure only the specific comment-reading endpoints are allowed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a great set of default permissions. However, several commands in the allow list can perform file modification, overwriting, or deletion. To prevent accidental data loss or corruption if the AI makes a mistake, it would be safer to move these to the ask list to require user confirmation.
The commands I recommend moving are:
Bash(echo:*)andBash(printf:*): Can overwrite files using redirection (>).Bash(sed:*)andBash(awk:*): Can modify files in-place (e.g.,sed -i) or write to new files.Bash(cp:*),Bash(copy:*),Bash(mv:*), andBash(move:*): Can overwrite or move files, which can be destructive.Bash(git rm:*)andBash(git mv:*): These commands remove files from the working directory. For consistency withrmbeing in theasklist and for general safety, they should also require confirmation.
Moving these to ask would provide a crucial safety layer for developers using this example configuration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'git stash drop' and 'git stash pop' commands are listed separately (lines 49-50) in addition to the general 'git stash' command (line 48). Since 'Bash(git stash:*)' would already match 'git stash drop' and 'git stash pop' due to the wildcard pattern, these specific entries are redundant and can be removed.