cc-workspace 4.1.2 → 4.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -340,6 +340,15 @@ Both `init` and `update` are safe to re-run:
340
340
 
341
341
  ---
342
342
 
343
+ ## Changelog v4.1.0 -> v4.1.2
344
+
345
+ | # | Fix | Detail |
346
+ |---|-----|--------|
347
+ | 1 | **Hook paths use `$CLAUDE_PROJECT_DIR`** | All 11 hooks in settings.json now resolve via `${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/` instead of relative `.claude/hooks/`. Fixes `WorktreeCreate hook failed: No such file or directory` when subagents run from a different CWD (worktree in sibling repo). |
348
+ | 2 | **stdout/stderr fix on 3 hooks** | `worktree-create-context.sh`: stdout was interpreted as worktree path — moved to stderr. `task-completed-check.sh` and `teammate-idle-check.sh`: stdout ignored by Claude Code for these events — moved to stderr. |
349
+
350
+ ---
351
+
343
352
  ## Changelog v4.0.5 -> v4.1.0
344
353
 
345
354
  | # | Feature | Detail |
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env bash
2
2
  # task-completed-check.sh
3
3
  # TaskCompleted hook: reminds teammates to verify tests/dead code/constitution.
4
- # Exit 0 + stdout = inject reminder as context (non-blocking, v4.0).
4
+ # TeammateIdle/TaskCompleted use stderr for feedback (stdout is ignored).
5
5
  set -euo pipefail
6
6
 
7
7
  INPUT=$(cat)
@@ -10,12 +10,8 @@ INPUT=$(cat)
10
10
  TASK_OUTPUT=$(echo "$INPUT" | jq -r '.task_output // empty' 2>/dev/null) || true
11
11
 
12
12
  # Check for explicit failure signals across common test runners
13
- # PHPUnit: FAILURES!, ERRORS!, Tests: X, Failures: Y
14
- # pytest/vitest/jest: FAILED, failed, ✗, Error
15
- # Pest (Laravel): FAIL, Tests: X, X failed
16
- # Generic: exit code non-zero indicators, AssertionError (Python), AssertionError (various)
17
13
  if echo "$TASK_OUTPUT" | grep -qiE '(tests?\s*fail|FAIL(ED|URES?)|error.*test|test.*error|ERRORS?:|failures?:|AssertionError|exit\s*code\s*[1-9])' 2>/dev/null; then
18
- echo "[Warning] Tests appear to have failed. Verify before marking complete."
14
+ echo "[Warning] Tests appear to have failed. Verify before marking complete." >&2
19
15
  fi
20
- echo "Task completion checklist: 1) Verify tests passed 2) Check for dead code 3) Verify constitution compliance."
16
+ echo "Task completion checklist: 1) Verify tests passed 2) Check for dead code 3) Verify constitution compliance." >&2
21
17
  exit 0
@@ -20,7 +20,7 @@ if [ -d "$PROJECT_DIR/plans" ]; then
20
20
 
21
21
  if [ -n "$PENDING" ]; then
22
22
  PLAN_NAMES=$(echo "$PENDING" | xargs -I{} basename {} | tr '\n' ', ' | sed 's/,$//')
23
- echo "[Warning] Unassigned tasks remain in: $PLAN_NAMES. Consider claiming the next pending task."
23
+ echo "[Warning] Unassigned tasks remain in: $PLAN_NAMES. Consider claiming the next pending task." >&2
24
24
  exit 0
25
25
  fi
26
26
  fi
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env bash
2
2
  # worktree-create-context.sh
3
- # WorktreeCreate hook: logs worktree creation and reminds teammate to read repo CLAUDE.md.
4
- # Parses stdin JSON to extract the worktree path for a specific reminder.
3
+ # WorktreeCreate hook: reminds teammate to read repo CLAUDE.md.
4
+ # Messages go to stderr so stdout doesn't pollute the worktree path.
5
5
  set -euo pipefail
6
6
 
7
7
  INPUT=$(cat)
@@ -9,14 +9,13 @@ INPUT=$(cat)
9
9
  WORKTREE_PATH=$(echo "$INPUT" | jq -r '.worktree_path // empty' 2>/dev/null) || true
10
10
 
11
11
  if [ -n "$WORKTREE_PATH" ]; then
12
- echo "[WorktreeCreate] Worktree created at: $WORKTREE_PATH"
13
12
  if [ -f "$WORKTREE_PATH/CLAUDE.md" ]; then
14
- echo "Read $WORKTREE_PATH/CLAUDE.md first — follow its conventions."
13
+ echo "Read $WORKTREE_PATH/CLAUDE.md first — follow its conventions." >&2
15
14
  else
16
- echo "WARNING: No CLAUDE.md found in $WORKTREE_PATH. Check repo root or run bootstrap-repo."
15
+ echo "WARNING: No CLAUDE.md found in $WORKTREE_PATH. Check repo root or run bootstrap-repo." >&2
17
16
  fi
18
17
  else
19
- echo "[WorktreeCreate] Worktree created. Read the CLAUDE.md in the repo root first."
18
+ echo "Read the CLAUDE.md in the repo root first." >&2
20
19
  fi
21
20
 
22
21
  exit 0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cc-workspace",
3
- "version": "4.1.2",
3
+ "version": "4.1.3",
4
4
  "description": "Claude Code multi-workspace orchestrator — skills, hooks, agents, and templates for multi-service projects",
5
5
  "bin": {
6
6
  "cc-workspace": "./bin/cli.js"