catalyst-os 2.0.0 → 2.0.2
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.
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
# Rename session to spec slug when /forge-spec or /forge-spec-worktree is invoked.
|
|
3
|
+
# Triggered by UserPromptSubmit hook.
|
|
4
|
+
|
|
5
|
+
PROMPT="$USER_PROMPT"
|
|
6
|
+
|
|
7
|
+
# Match /forge-spec or /forge-spec-worktree followed by a spec argument
|
|
8
|
+
if echo "$PROMPT" | grep -qE '^/forge-spec(-worktree)?\s+'; then
|
|
9
|
+
SLUG=$(echo "$PROMPT" | sed -E 's|^/forge-spec(-worktree)?\s+||' | sed 's/^@//' | xargs)
|
|
10
|
+
|
|
11
|
+
if [ -n "$SLUG" ]; then
|
|
12
|
+
cat <<EOF
|
|
13
|
+
{
|
|
14
|
+
"hookSpecificOutput": {
|
|
15
|
+
"hookEventName": "UserPromptSubmit",
|
|
16
|
+
"sessionTitle": "$SLUG"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
EOF
|
|
20
|
+
fi
|
|
21
|
+
fi
|
package/.claude/settings.json
CHANGED
|
@@ -1,14 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"hooks": {
|
|
3
|
+
"UserPromptSubmit": [
|
|
4
|
+
{
|
|
5
|
+
"matcher": "^/forge-spec",
|
|
6
|
+
"hooks": [
|
|
7
|
+
{
|
|
8
|
+
"type": "command",
|
|
9
|
+
"command": ".claude/hooks/forge-session-rename.sh"
|
|
10
|
+
}
|
|
11
|
+
]
|
|
12
|
+
}
|
|
13
|
+
],
|
|
3
14
|
"PostToolUse": [
|
|
4
15
|
{
|
|
5
16
|
"matcher": "Edit|Write",
|
|
6
|
-
"
|
|
17
|
+
"hooks": [
|
|
18
|
+
{
|
|
19
|
+
"type": "command",
|
|
20
|
+
"command": ".claude/hooks/post-edit-format.sh $FILE_PATH"
|
|
21
|
+
}
|
|
22
|
+
]
|
|
7
23
|
}
|
|
8
24
|
],
|
|
9
25
|
"PreCompact": [
|
|
10
26
|
{
|
|
11
|
-
"
|
|
27
|
+
"matcher": "",
|
|
28
|
+
"hooks": [
|
|
29
|
+
{
|
|
30
|
+
"type": "command",
|
|
31
|
+
"command": ".claude/hooks/pre-compact-save.sh"
|
|
32
|
+
}
|
|
33
|
+
]
|
|
12
34
|
}
|
|
13
35
|
]
|
|
14
36
|
}
|
|
@@ -71,7 +71,17 @@ Move spec to completed path:
|
|
|
71
71
|
|
|
72
72
|
Update spec.md status to COMPLETE.
|
|
73
73
|
|
|
74
|
-
### Phase 7:
|
|
74
|
+
### Phase 7: Push & Pull Request
|
|
75
|
+
|
|
76
|
+
1. Read `git.development_branch` from `.catalyst/main/project-config.yaml` (e.g., `development`, `staging`)
|
|
77
|
+
2. Push the feature branch: `git push -u origin {branch-name}`
|
|
78
|
+
3. Create a PR targeting the development branch:
|
|
79
|
+
```
|
|
80
|
+
gh pr create --base {development_branch} --title "feat({scope}): {spec title}" --body "..."
|
|
81
|
+
```
|
|
82
|
+
4. Include spec summary, TDD stats, and file change counts in the PR body
|
|
83
|
+
|
|
84
|
+
### Phase 8: Self-Documentation
|
|
75
85
|
|
|
76
86
|
Propagate learnings from completed spec back to project docs:
|
|
77
87
|
|
|
@@ -79,7 +89,7 @@ Propagate learnings from completed spec back to project docs:
|
|
|
79
89
|
2. **architecture.md** — Add key files from `key_files`
|
|
80
90
|
3. **concerns.md** — Mark resolved issues from `issues_resolved`
|
|
81
91
|
|
|
82
|
-
### Phase
|
|
92
|
+
### Phase 9: Library Extraction (Optional)
|
|
83
93
|
|
|
84
94
|
Auto-detect reusable patterns from spec name/content. Ask user if spec should be added to pattern library. If yes, delegate to Scribe for extraction.
|
|
85
95
|
|
|
@@ -99,5 +109,5 @@ Self-Documentation:
|
|
|
99
109
|
|
|
100
110
|
Library: {status}
|
|
101
111
|
|
|
102
|
-
|
|
112
|
+
PR: {pr-url}
|
|
103
113
|
```
|