You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
chore(workflows): run Claude review once per PR and on manual trigger
- Update workflow to trigger only on PR open/reopen and manual comment
- Add concurrency group to ensure single review per PR at a time
- Improve documentation and add workflow example for clarity
- Move request tracing info to README and update troubleshooting steps
* Claude refuses dangerous permissions - YOLO mode runs as non-root + adds `--dangerously-skip-permissions`
144
+
* Claude refuses dangerous permissions on root user - YOLO mode runs as non-root + adds `--dangerously-skip-permissions`
107
145
* Running in home directory - Script warns and requires confirmation, always cd to project first
108
146
109
147
## Development Tools Included
@@ -114,112 +152,3 @@ Docker container automatically translates `127.0.0.1` and `localhost` to `host.d
114
152
**Editors**: vim, neovim, nano
115
153
**Shell**: zsh with oh-my-zsh and plugins
116
154
**Claude**: claude, claude-trace pre-installed
117
-
118
-
## Request Tracing Support
119
-
120
-
Claude Code YOLO integrates with [claude-trace](https://github.com/badlogic/lemmy/tree/main/apps/claude-trace) for detailed request logging and debugging.
121
-
122
-
**Installation:**
123
-
```bash
124
-
npm install -g @mariozechner/claude-trace
125
-
```
126
-
127
-
**Usage:**
128
-
```bash
129
-
# Enable tracing in local mode
130
-
./claude.sh --trace .
131
-
132
-
# Enable tracing in YOLO mode
133
-
./claude.sh --yolo --trace .
134
-
135
-
# Bedrock with tracing
136
-
./claudeb.sh --trace .
137
-
```
138
-
139
-
**Features:**
140
-
- Logs all Claude API requests and responses
141
-
- Saves trace files to `.claude-trace/` directory
142
-
- Includes full request/response headers and timing
143
-
- Useful for debugging authentication issues and API usage
144
-
145
-
## Common Development Commands
146
-
147
-
### Building and Testing
148
-
```bash
149
-
# Build Docker image
150
-
make build
151
-
152
-
# Rebuild without cache
153
-
make rebuild
154
-
155
-
# Test the built image
156
-
make test
157
-
158
-
# Test with current directory mounted
159
-
make test-local
160
-
161
-
# Build and test in one command
162
-
make build-test
163
-
164
-
# Open development shell
165
-
make dev
166
-
```
167
-
168
-
### Running Claude
169
-
```bash
170
-
# Quick YOLO mode (recommended)
171
-
./claude-yolo .# Local script
172
-
claude-yolo .# If installed globally
173
-
174
-
# Full wrapper options
175
-
./claude.sh --yolo .# YOLO mode in Docker
176
-
./claude.sh .# Local mode (no Docker)
177
-
./claude.sh --api-key .# Use API key auth
178
-
./claude.sh --bedrock .# Use AWS Bedrock
179
-
./claude.sh --vertex .# Use Google Vertex AI
180
-
./claude.sh --shell # Open shell in container
181
-
./claude.sh --trace .# Enable request tracing
182
-
```
183
-
184
-
### Container Management
185
-
```bash
186
-
# Clean up Docker artifacts
187
-
make clean
188
-
189
-
# Deep clean including BuildKit cache
190
-
make clean-all
191
-
192
-
# Show image information and size
193
-
make info
194
-
195
-
# Check build context size
196
-
make context-size
197
-
198
-
# Lint Dockerfile (requires hadolint)
199
-
make lint
200
-
```
201
-
202
-
## Debug and Troubleshooting Commands
203
-
204
-
### Authentication Debugging
205
-
```bash
206
-
# Test different auth methods with tracing
207
-
./claude.sh --claude --trace .# OAuth debugging
208
-
./claude.sh --api-key --trace .# API key debugging
-**Request Tracing**: Debug with `--trace` flag using claude-trace
118
118
-**Docker Socket**: Optional mounting with `CLAUDE_YOLO_DOCKER_SOCKET=true`
119
119
120
+
121
+
### Request Tracing by @badlogic`claude-trace`
122
+
123
+
Claude Code YOLO integrates with [claude-trace](https://github.com/badlogic/lemmy/tree/main/apps/claude-trace) for detailed request logging and debugging.
124
+
120
125
## Docker Images
121
126
122
127
Claude Code YOLO is available from multiple container registries:
# * **Auto review**: run on `pull_request_target` only when the PR is **opened** or **re-opened**—not on every push (`synchronize`).
4
+
# * **Opt-in re-review**: listen on `issue_comment` and run again only if the comment body contains `/claude-review`.
5
+
# * Optional `workflow_dispatch` makes the “Run workflow” button available in the UI.
6
+
7
+
# 2. **One job per PR at a time**
8
+
9
+
# * Use `concurrency.group = "claude-review-${PR_NUMBER}"`; `cancel-in-progress: false` lets earlier runs finish while preventing duplicate parallel runs.
10
+
11
+
# 3. **Job guard**
12
+
13
+
# * Single job guarded with an `if:` expression so it fires only for the two allowed scenarios above.
14
+
15
+
# 4. **Minimal permissions**
16
+
17
+
# * `pull-requests: write` → post review comments.
18
+
# * `issues: write` → reply to the `/claude-review` trigger comment.
19
+
20
+
# 5. **Run the Claude action**
21
+
22
+
# * Swap the placeholder `anthropic-ai/claude-code-review@v1` for whatever revision you actually use.
23
+
24
+
# 6. **(Optional) Reply to manual trigger**
25
+
26
+
# * A short “review queued” reply helps contributors know their command was accepted.
27
+
28
+
# The finished workflow file **`.github/workflows/claude-review.yml`** is now in the canvas—feel free to tweak the action version, the trigger phrase, or remove the reply step if you don’t need it.
29
+
30
+
# ---
31
+
32
+
# Auto‑run Claude code review exactly once per PR, and allow opt‑in re‑reviews
33
+
name: "Claude Code Review"
34
+
35
+
on:
36
+
# --- automatic run ---
37
+
# Trigger only when a PR is first opened or later re‑opened.
38
+
pull_request_target:
39
+
types: [opened, reopened]
40
+
41
+
# --- manual re‑review ---
42
+
# Listen for a PR comment that contains the magic string "/claude-review".
43
+
issue_comment:
44
+
types: [created]
45
+
46
+
# Optional: enable the "Run workflow" button in the Actions tab.
47
+
workflow_dispatch:
48
+
49
+
# Ensure one review job per PR runs at a time under the same key
0 commit comments