Skip to content

chore(repo): Add Claude Code settings with basic permissions#959

Merged
szokeasaurusrex merged 7 commits intomasterfrom
chore/add-claude-settings
Feb 16, 2026
Merged

chore(repo): Add Claude Code settings with basic permissions#959
szokeasaurusrex merged 7 commits intomasterfrom
chore/add-claude-settings

Conversation

@philipphofmann
Copy link
Member

Adds .claude/settings.json to enable Claude Code with:

  • Basic bash commands (find, ls, git, grep, mv)
  • WebFetch access to GitHub and Sentry documentation sites

This follows the same pattern used in other Sentry SDK repositories like sentry-javascript, sentry-dart, and sentry-react-native.

Note: This adds .claude/settings.json with -f flag since .claude is in .gitignore for local settings.

Adds .claude/settings.json to enable Claude Code with:
- Basic bash commands (find, ls, git, grep, mv)
- WebFetch access to GitHub and Sentry documentation sites

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@szokeasaurusrex
Copy link
Member

I am not sure how I feel about this change; I think permissions settings are something that developers should configure for themselves. @lcian what do you think?

@philipphofmann
Copy link
Member Author

@szokeasaurusrex, this is a handy default set of permissions for Claude across all SDKs and developers. You can still keep personal permissions locally for every dev. Sharing defaults helps everyone get started faster, but it’s totally optional—use them if you want, or just close the PR if not.

@lcian
Copy link
Member

lcian commented Jan 28, 2026

I think as long as the commands cannot introduce any security problems in the developer's environment, this is not a big deal.
find could in theory be used to execute arbitrary commands so that could be the only concern.

Copy link
Member

@szokeasaurusrex szokeasaurusrex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, you have convinced me that having defaults in the repo makes sense. But, I do have some opinions on some of the permissions.

I myself typically am okay with the agent taking more permissions, but I am not using YOLO mode. I also know that other devs may not want their agents to have that many permissions, so the defaults should be conservative imo.

philipphofmann and others added 5 commits January 29, 2026 16:58
Co-authored-by: Daniel Szoke <daniel.szoke@sentry.io>
Co-authored-by: Daniel Szoke <daniel.szoke@sentry.io>
Co-authored-by: Daniel Szoke <daniel.szoke@sentry.io>
Co-authored-by: Daniel Szoke <daniel.szoke@sentry.io>
@szokeasaurusrex szokeasaurusrex enabled auto-merge (squash) February 16, 2026 13:38
"Bash(gh repo view:*)",
"WebFetch(domain:docs.sentry.io)",
"WebFetch(domain:develop.sentry.dev)",
"Bash(grep:*)",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: The .claude/settings.json file contains a trailing comma after the last array element. This is invalid in strict JSON and will cause a parsing error.
Severity: HIGH

Suggested Fix

Remove the trailing comma from line 26 in .claude/settings.json. The line should be changed from "Bash(grep:*)", to "Bash(grep:*)" to make the JSON file valid.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: .claude/settings.json#L26

Potential issue: The `.claude/settings.json` file contains a trailing comma on line 26
after the last element in an array. The Claude Code tool, which consumes this file, uses
a strict JSON parser that does not permit trailing commas. This will cause a parsing
failure when the tool attempts to load the configuration. Consequently, the settings
defined in the file, such as permissions for bash commands, will not be applied, and the
tool will fall back to default or more restrictive settings. The primary goal of the
pull request—to configure Claude Code—will not be achieved.

Did we get this right? 👍 / 👎 to inform future reviews.

@szokeasaurusrex szokeasaurusrex merged commit 108c51d into master Feb 16, 2026
23 checks passed
@szokeasaurusrex szokeasaurusrex deleted the chore/add-claude-settings branch February 16, 2026 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants