ace-git 0.28.1 โ†’ 0.30.0

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.
@@ -1,282 +0,0 @@
1
- ---
2
- doc-type: workflow
3
- title: Pull Request Creation Workflow
4
- purpose: pull request creation workflow
5
- ace-docs:
6
- last-updated: 2026-03-04
7
- last-checked: 2026-03-21
8
- ---
9
-
10
- # Pull Request Creation Workflow
11
-
12
- ## Purpose
13
-
14
- Create pull requests with descriptions sourced from code evidence (diff, commits, tests, changelogs), using consistent section structure.
15
-
16
- ## Variables
17
-
18
- - `$pr_type`: `feature`, `bugfix`, or `default`
19
- - `$target_branch`: target branch (default resolved from task/worktree context)
20
- - `$draft`: create as draft (`false` by default)
21
-
22
- ## Instructions
23
-
24
- ### 1. Pre-PR Verification
25
-
26
- ```bash
27
- git branch --show-current
28
- git status
29
- git log origin/${target_branch:-main}..HEAD --oneline
30
- ace-test
31
- ```
32
-
33
- Checklist:
34
- - [ ] All changes committed
35
- - [ ] Relevant tests pass
36
- - [ ] CHANGELOG updated if release notes changed
37
- - [ ] No sensitive data in diff
38
-
39
- ### 2. Resolve Target Branch
40
-
41
- Prefer task/worktree metadata from `_current/*.s.md` (`worktree.target_branch`), fallback to `main`.
42
-
43
- ```bash
44
- task_file=$(ls _current/*.s.md 2>/dev/null | head -1)
45
- ```
46
-
47
- If subtask context exists and current target is `main`, switch target to parent task branch.
48
-
49
- ### 3. Push Branch
50
-
51
- ```bash
52
- git push -u origin "$(git branch --show-current)"
53
- ```
54
-
55
- **If push is rejected (non-fast-forward)**:
56
- - For feature branches with worktree-based divergence, prefer `git push --force-with-lease`
57
- - For shared branches or uncertain divergence, ask the user before force-pushing or rebasing
58
- - Do NOT silently rebase โ€” this is a potentially destructive operation requiring user consent
59
-
60
- ### 4. Build Evidence Inputs
61
-
62
- Before writing the body, collect evidence:
63
-
64
- ```bash
65
- git log origin/${target_branch:-main}..HEAD --oneline
66
- ace-git diff --format grouped-stats
67
- ```
68
-
69
- And collect:
70
- - Behavioral evidence from diff (old behavior vs new behavior)
71
- - Test evidence (test names -> behavior proved, suite totals)
72
- - Release evidence (CHANGELOG additions)
73
-
74
- ### 5. Draft PR Body with Required Sections
75
-
76
- Use this order:
77
-
78
- ```markdown
79
- ## ๐Ÿ“‹ Summary
80
- ## โœ๏ธ Changes
81
- ## ๐Ÿ“ File Changes
82
- ## ๐Ÿงช Test Evidence
83
- ## ๐Ÿ“ฆ Releases
84
- ## ๐ŸŽฎ Demo
85
- ```
86
-
87
- Section sourcing rules:
88
-
89
- | Section | Data Source | Avoid |
90
- |---|---|---|
91
- | Summary | Diff behavior and user pain removed | Restating task objective text |
92
- | Changes | Concern-grouped code changes linked to commits | Raw commit dump |
93
- | File Changes | `ace-git diff --format grouped-stats` | Manual unstructured file list |
94
- | Test Evidence | Test names mapped to behaviors + totals | Raw command output paste |
95
- | Releases | CHANGELOG diff entries | Duplicating Changes section |
96
- | Demo | Runnable commands from README/usage.md + observed output | Screenshots, prose-only descriptions without commands |
97
-
98
- **Grouped-stats formatting rule:**
99
- - The `## ๐Ÿ“ File Changes` section must wrap grouped-stats output inside a fenced code block (```)
100
- - Paste the output exactly as produced โ€” preserve all column alignment, tree indentation, and emoji markers
101
- - Never convert grouped-stats output into bullet lists, tables, or prose
102
-
103
- Summary writing rules:
104
- - Start with what is easier now
105
- - Mention what users/reviewers had to do before
106
- - Do not lead with method/class names
107
- - Do not use task-spec text as prose source
108
-
109
- Bullet formatting rules:
110
- - **Bold the first key term** in each bullet (feature name, class name, CLI flag, or config key) so it serves as a visual anchor before the explanation. Example: `- Add **\`GroupedStatsFormatter\`**: formats numstat output into...`
111
- - In Test Evidence, bold the test class name: `- **GroupedStatsFormatterTest** (6 tests) โ€” validates...`
112
- - In Releases, bold the package+version: `- **ace-git v0.11.0โ€“v0.11.6** โ€” Add grouped-stats format...`
113
-
114
- Demo section rules:
115
- - Include `## ๐ŸŽฎ Demo` when the PR introduces a user-facing CLI or runnable entry point
116
- - Structure: `### Run` (exact command), `### Expected Output`, `### Artifacts` (where to find results)
117
- - Omit when: no user-facing CLI, no runnable entry point, or purely internal refactoring
118
-
119
- Omission/fallback rules:
120
- - No changelog evidence -> omit `## ๐Ÿ“ฆ Releases`
121
- - No test-file evidence -> `## ๐Ÿงช Test Evidence` may include totals-only validation
122
- - grouped-stats unavailable -> fallback to flat file list in `## ๐Ÿ“ File Changes`
123
- - No user-facing CLI or runnable entry point -> omit `## ๐ŸŽฎ Demo`
124
- - Omit any section lacking evidence; never leave empty placeholders
125
-
126
- #### Grouped-stats example
127
-
128
- Correct โ€” output wrapped in a fenced code block preserving all formatting:
129
-
130
- ````
131
- ## ๐Ÿ“ File Changes
132
-
133
- ```
134
- +762, -54 34 files total
135
-
136
- +358, -35 10 files ace-overseer/
137
- +117, -18 4 files ๐Ÿงฑ lib/
138
- +19, -3 ace/overseer/cli/commands/work_on.rb
139
- ```
140
- ````
141
-
142
- Incorrect โ€” reformatted into bullet list (loses tree structure and alignment):
143
-
144
- ```
145
- ## ๐Ÿ“ File Changes
146
-
147
- - ace-overseer/lib/ace/overseer/cli/commands/work_on.rb (+19, -3)
148
- - ace-overseer/lib/ace/overseer/molecules/assignment_launcher.rb (+42, -8)
149
- ```
150
-
151
- ### 6. Create PR
152
-
153
- ```bash
154
- gh pr create \
155
- --title "<task-id-or-type>: <user-impact-description>" \
156
- --body-file pr-description.md \
157
- --base "${target_branch:-main}"
158
- ```
159
-
160
- Optional draft mode:
161
-
162
- ```bash
163
- gh pr create --draft --title "..." --body-file pr-description.md --base "${target_branch:-main}"
164
- ```
165
-
166
- ### 7. Add Metadata (Optional)
167
-
168
- ```bash
169
- gh pr edit --add-reviewer @reviewer1,@reviewer2
170
- gh pr edit --add-label "enhancement,needs-review"
171
- ```
172
-
173
- ### 8. Verify PR
174
-
175
- ```bash
176
- gh pr view
177
- gh pr checks
178
- ```
179
-
180
- ## Success Criteria
181
-
182
- - PR created with evidence-based body
183
- - Section order matches required structure
184
- - Summary is user-impact-first and task-spec-independent
185
- - File changes sourced from grouped-stats (or fallback)
186
- - Test evidence maps tests to behavior
187
- - Releases only included when changelog evidence exists
188
-
189
- ## Response Template
190
-
191
- **PR Created:** [URL]
192
- **PR Number:** #[number]
193
- **Title:** [PR title]
194
- **Type:** [feature/bugfix/default]
195
- **Status:** [created|draft|failed]
196
-
197
- <documents>
198
- <template path="ace-git/handbook/templates/pr/feature.template.md">
199
- ## ๐Ÿ“‹ Summary
200
-
201
- [What is easier now for users/reviewers]
202
- [What pain/manual step/error existed before]
203
-
204
- ## โœ๏ธ Changes
205
-
206
- - Add **`[FeatureName]`**: [what it does]
207
- - Add **`[ClassName]`** to [what it enables]
208
-
209
- ## ๐Ÿ“ File Changes
210
-
211
- [Paste `ace-git diff --format grouped-stats` output verbatim inside a fenced code block โ€” preserve all spacing and tree structure]
212
- [Fallback: flat file list if grouped-stats unavailable]
213
-
214
- ## ๐Ÿงช Test Evidence
215
-
216
- - **[TestClassName]** ([N] tests) โ€” [behavior validated]
217
- - Suite totals: [passed]/[total]
218
-
219
- ## ๐Ÿ“ฆ Releases
220
-
221
- - **[package vX.Y.Z]** โ€” [CHANGELOG entry from diff]
222
-
223
- ## ๐ŸŽฎ Demo
224
-
225
- [Runnable command(s) demonstrating the feature โ€” omit section if no user-facing CLI]
226
- [Expected output and artifact locations]
227
- </template>
228
-
229
- <template path="ace-git/handbook/templates/pr/bugfix.template.md">
230
- ## ๐Ÿ“‹ Summary
231
-
232
- [What broke and what is now fixed]
233
-
234
- ## โœ๏ธ Changes
235
-
236
- - Fix **`[ErrorType]`** when [condition] ([commit-sha])
237
- - Add **`[TestName]`** to guard against regression ([commit-sha])
238
-
239
- ## ๐Ÿ“ File Changes
240
-
241
- [Paste `ace-git diff --format grouped-stats` output verbatim inside a fenced code block โ€” preserve all spacing and tree structure]
242
-
243
- ## ๐Ÿงช Test Evidence
244
-
245
- - **[TestClassName]** ([N] tests) โ€” [regression behavior covered]
246
- - Suite totals: [passed]/[total]
247
-
248
- ## ๐Ÿ“ฆ Releases
249
-
250
- - **[package vX.Y.Z]** โ€” [CHANGELOG fix entry from diff]
251
- </template>
252
-
253
- <template path="ace-git/handbook/templates/pr/default.template.md">
254
- ## ๐Ÿ“‹ Summary
255
-
256
- [What is easier now]
257
- [What changed from user/reviewer perspective]
258
-
259
- ## โœ๏ธ Changes
260
-
261
- - Add **`[PrimaryChange]`**: [description] ([commit-sha])
262
- - Update **`[SecondaryChange]`**: [description] ([commit-sha])
263
-
264
- ## ๐Ÿ“ File Changes
265
-
266
- [Paste `ace-git diff --format grouped-stats` output verbatim inside a fenced code block โ€” preserve all spacing and tree structure]
267
-
268
- ## ๐Ÿงช Test Evidence
269
-
270
- - **[TestClassName]** ([N] tests) โ€” [behavior validated]
271
- - Suite totals: [passed]/[total]
272
-
273
- ## ๐Ÿ“ฆ Releases
274
-
275
- - **[package vX.Y.Z]** โ€” [CHANGELOG entry from diff, if any]
276
-
277
- ## ๐ŸŽฎ Demo
278
-
279
- [Runnable command(s) demonstrating the change โ€” omit section if no user-facing CLI]
280
- [Expected output and artifact locations]
281
- </template>
282
- </documents>
@@ -1,203 +0,0 @@
1
- ---
2
- doc-type: workflow
3
- title: Update PR Description Workflow
4
- purpose: evidence-based PR documentation
5
- ace-docs:
6
- last-updated: 2026-03-04
7
- last-checked: 2026-03-21
8
- ---
9
-
10
- # Update PR Description Workflow
11
-
12
- ## Purpose
13
-
14
- Generate PR titles and descriptions from code evidence in the PR (diff, commits, tests, and changelog entries), not from task specification text.
15
-
16
- ## Variables
17
-
18
- - `$pr_number`: PR number to update (optional - auto-detect from current branch)
19
-
20
- ## Instructions
21
-
22
- ### 1. Resolve PR Number
23
-
24
- ```bash
25
- gh pr view --json number -q .number
26
- ```
27
-
28
- If no PR exists for current branch, ask the user for the target PR number.
29
-
30
- ### 2. Verify Target Branch
31
-
32
- ```bash
33
- gh pr view $pr_number --json baseRefName,headRefName,title
34
- ace-task status
35
- ```
36
-
37
- If taskflow context indicates a subtask and the PR targets `main`, retarget to the parent task branch before continuing.
38
-
39
- ### 3. Collect Evidence Inputs
40
-
41
- Collect the evidence used to write the PR:
42
-
43
- ```bash
44
- # Changed files
45
- gh pr diff $pr_number --name-only
46
-
47
- # Full diff for behavior and error-message changes
48
- gh pr diff $pr_number
49
-
50
- # Commit headlines
51
- gh pr view $pr_number --json commits -q '.commits[].messageHeadline'
52
-
53
- # File-change grouping (preferred)
54
- ace-git diff $(git merge-base HEAD origin/main)..HEAD --format grouped-stats
55
- ```
56
-
57
- Also gather test evidence and release evidence:
58
- - Test evidence: test files changed in diff + relevant test outputs/suite totals
59
- - Release evidence: CHANGELOG entries present in diff
60
-
61
- ### 4. Generate Evidence-Based Title
62
-
63
- Title format:
64
- - If task ID available from `ace-git status --no-pr`: `<task-id>: <description>`
65
- - Otherwise: `<type>(<scope>): <description>`
66
-
67
- Title guidance:
68
- - Focus on user-facing impact
69
- - Keep concise (target < 60 chars after task-id)
70
- - Do not lead with class/method names unless unavoidable
71
-
72
- ### 5. Generate PR Description
73
-
74
- Use this section order exactly:
75
-
76
- ```markdown
77
- ## ๐Ÿ“‹ Summary
78
- ## โœ๏ธ Changes
79
- ## ๐Ÿ“ File Changes
80
- ## ๐Ÿงช Test Evidence
81
- ## ๐Ÿ“ฆ Releases
82
- ## ๐ŸŽฎ Demo
83
- ```
84
-
85
- Section sourcing rules:
86
-
87
- | Section | Required Source | Avoid |
88
- |---|---|---|
89
- | Summary | Behavioral change in diff + commit intent | Task spec objective text |
90
- | Changes | Concern-grouped diff changes, traced to commits | Raw commit list dump |
91
- | File Changes | `ace-git diff $(git merge-base HEAD origin/main)..HEAD --format grouped-stats` output, pasted verbatim and in full | Manual hand-written file listing, trimming or abbreviating the grouped-stats output |
92
- | Test Evidence | Test names mapped to behaviors + suite totals | Raw unstructured test output paste |
93
- | Releases | CHANGELOG entries from diff | Repeating content already in Changes |
94
- | Demo | Runnable commands from README/usage.md + observed output | Screenshots, prose-only descriptions without commands |
95
-
96
- **Grouped-stats formatting rule:**
97
- - The `## ๐Ÿ“ File Changes` section must wrap grouped-stats output inside a fenced code block (```)
98
- - Paste the output exactly as produced โ€” preserve all column alignment, tree indentation, and emoji markers
99
- - Never convert grouped-stats output into bullet lists, tables, or prose
100
-
101
- Bullet formatting rules:
102
- - **Bold the first key term** in each bullet (feature name, class name, CLI flag, or config key) so it serves as a visual anchor before the explanation. Example: `- Add **\`GroupedStatsFormatter\`**: formats numstat output into...`
103
- - In Test Evidence, bold the test class name: `- **GroupedStatsFormatterTest** (6 tests) โ€” validates...`
104
- - In Releases, bold the package+version: `- **ace-git v0.11.0โ€“v0.11.6** โ€” Add grouped-stats format...`
105
-
106
- ### 6. Summary Writing Rules
107
-
108
- Write Summary in this sequence:
109
- 1. What is easier now for users/reviewers
110
- 2. What pain/manual step/error state existed before
111
- 3. What changed to remove that pain
112
-
113
- Constraints:
114
- - Do not copy wording from task specs
115
- - Do not start with method/class names
116
- - Prefer behavior language over implementation language
117
-
118
- ### 7. Demo Section Rules
119
-
120
- Include `## ๐ŸŽฎ Demo` when the PR introduces a user-facing CLI command or runnable entry point that a reviewer can try.
121
-
122
- When a PR adds or changes multiple distinct user-facing modes, list each mode explicitly in `## ๐ŸŽฎ Demo` instead of showing only one representative command. Examples: mutually exclusive flags (`--yaml` vs `--task`) or sibling commands like `add --step`, `add --yaml`, and `add --task`.
123
-
124
- Structure:
125
-
126
- ```markdown
127
- ## ๐ŸŽฎ Demo
128
-
129
- ### Run
130
- \`\`\`bash
131
- [exact commands to copy-paste]
132
- \`\`\`
133
-
134
- ### Expected Output
135
- [what the reviewer should see]
136
-
137
- ### Artifacts
138
- [where to find generated files]
139
- ```
140
-
141
- Omit when: the PR has no user-facing CLI, no runnable entry point, or is purely internal refactoring.
142
-
143
- **Recorded demo integration**: If a recorded demo GIF has been attached as a PR comment (via `ace-demo record --pr`), reference it in the Demo section: "See attached demo recording in PR comments below" alongside the runnable commands. The recorded demo supplements but does not replace the runnable commands.
144
-
145
- ### 8. Omission and Fallback Rules
146
-
147
- - If no changelog evidence: omit `## ๐Ÿ“ฆ Releases`
148
- - If no test-file evidence: keep `## ๐Ÿงช Test Evidence` with suite totals only
149
- - If `ace-git diff $(git merge-base HEAD origin/main)..HEAD --format grouped-stats` is unavailable: use flat file list fallback under `## ๐Ÿ“ File Changes`
150
- - If no user-facing CLI or runnable entry point: omit `## ๐ŸŽฎ Demo`
151
- - Omit sections with no supporting evidence instead of leaving placeholders
152
-
153
- #### Grouped-stats example
154
-
155
- Correct โ€” output wrapped in a fenced code block preserving all formatting:
156
-
157
- ````
158
- ## ๐Ÿ“ File Changes
159
-
160
- ```
161
- +762, -54 34 files total
162
-
163
- +358, -35 10 files ace-overseer/
164
- +117, -18 4 files ๐Ÿงฑ lib/
165
- +19, -3 ace/overseer/cli/commands/work_on.rb
166
- ```
167
- ````
168
-
169
- Incorrect โ€” reformatted into bullet list (loses tree structure and alignment):
170
-
171
- ```
172
- ## ๐Ÿ“ File Changes
173
-
174
- - ace-overseer/lib/ace/overseer/cli/commands/work_on.rb (+19, -3)
175
- - ace-overseer/lib/ace/overseer/molecules/assignment_launcher.rb (+42, -8)
176
- ```
177
-
178
- ### 9. Update PR
179
-
180
- ```bash
181
- gh pr edit $pr_number \
182
- --title "Generated title" \
183
- --body "$(cat <<'BODY'
184
- ## ๐Ÿ“‹ Summary
185
- ...
186
- BODY
187
- )"
188
- ```
189
-
190
- ### 10. Confirm Update
191
-
192
- ```bash
193
- gh pr view $pr_number --json url,title -q '.url + "\n" + .title'
194
- ```
195
-
196
- ## Success Criteria
197
-
198
- - Description uses: `๐Ÿ“‹ Summary -> โœ๏ธ Changes -> ๐Ÿ“ File Changes -> ๐Ÿงช Test Evidence -> ๐Ÿ“ฆ Releases -> ๐ŸŽฎ Demo`
199
- - Summary leads with user impact and does not restate task specs
200
- - File Changes contains the complete, untruncated grouped-stats output (never trimmed, summarised, or selectively omitted)
201
- - Test Evidence maps tests to behavior and includes totals
202
- - Releases derived from changelog evidence only
203
- - Empty/no-evidence sections are omitted