Skip to content

Commit d557f53

Browse files
committed
Add GH workflow
1 parent 28170ad commit d557f53

1 file changed

Lines changed: 45 additions & 0 deletions

File tree

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Check Claude Configuration
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- '.claude/**'
7+
- 'CLAUDE.md'
8+
9+
jobs:
10+
check-claude-config:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Check for Claude configuration changes
14+
uses: actions/github-script@v7
15+
with:
16+
script: |
17+
const comment = `⚠️ **Claude Configuration Warning**
18+
19+
You've modified Claude Code configuration files. These files contain the shared configuration for all contributors. Please revert this change if unintended. **ONLY modify these files if you need to change shared configurations that apply to everyone and have discussed this change with the TW team.**
20+
21+
To override the Claude settings locally, use \`.claude/settings.local.json\` instead.
22+
23+
**For example, if you're changing AWS_PROFILE:**
24+
The default profile name is \`my-sandbox\`. If your AWS profile has a different name, override it locally instead of changing the shared file.
25+
26+
Create or edit \`.claude/settings.local.json\` in the repo root and include the following lines:
27+
28+
\`\`\`json
29+
{
30+
"env": {
31+
"AWS_PROFILE": "your-sandbox-name"
32+
}
33+
}
34+
\`\`\`
35+
36+
This local file is gitignored and overrides the repo default.`;
37+
38+
github.rest.issues.createComment({
39+
issue_number: context.issue.number,
40+
owner: context.repo.owner,
41+
repo: context.repo.repo,
42+
body: comment
43+
});
44+
45+
core.setFailed('Claude configuration was modified - see comment for guidance');

0 commit comments

Comments
 (0)