<feed xmlns='http://www.w3.org/2005/Atom'>
<title>superpowers.git/tests/claude-code, branch dev</title>
<subtitle>Agentic skills framework and development workflow
</subtitle>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/'/>
<entry>
<title>Merge pull request #2606 from obra/fix/2429-sdd-repo-resolution</title>
<updated>2026-11-02T22:01:03+00:00</updated>
<author>
<name>Drew Ritter</name>
<email>drew@ritter.dev</email>
</author>
<published>2026-11-02T22:01:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=2f5dc3b335c05e8e3078c0be056c1001baa6b554'/>
<id>2f5dc3b335c05e8e3078c0be056c1001baa6b554</id>
<content type='text'>
fix(sdd): helpers act on the current directory's repo like git, with -C to override (#2429)</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fix(sdd): helpers act on the current directory's repo like git, with -C to override (#2429)</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #2605 from obra/fix/2436-task-brief-unclosed-fence</title>
<updated>2026-11-02T21:50:41+00:00</updated>
<author>
<name>Drew Ritter</name>
<email>drew@ritter.dev</email>
</author>
<published>2026-11-02T21:50:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=862308e2b3dade2c6df424115d86e7307961a129'/>
<id>862308e2b3dade2c6df424115d86e7307961a129</id>
<content type='text'>
fix(sdd): task-brief refuses a brief that an unclosed code fence would run to EOF (#2436)</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fix(sdd): task-brief refuses a brief that an unclosed code fence would run to EOF (#2436)</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #2604 from obra/fix/2459-2496-task-brief-headings</title>
<updated>2026-11-02T21:49:28+00:00</updated>
<author>
<name>Drew Ritter</name>
<email>drew@ritter.dev</email>
</author>
<published>2026-11-02T21:49:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=6aeac7ed95b1c31394eca620518e26d592ebd68d'/>
<id>6aeac7ed95b1c31394eca620518e26d592ebd68d</id>
<content type='text'>
fix(sdd): task-brief finds alphanumeric task IDs and explains non-English headings (#2459, #2496)</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fix(sdd): task-brief finds alphanumeric task IDs and explains non-English headings (#2459, #2496)</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): task-brief refuses a brief an unclosed code fence would run to EOF</title>
<updated>2026-10-23T03:38:19+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T22:26:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=3735a50d5ab4c77ffa0ec7f0423d7414415c0aab'/>
<id>3735a50d5ab4c77ffa0ec7f0423d7414415c0aab</id>
<content type='text'>
task-brief ignores Task headings inside fenced code blocks by toggling a
flag on every ``` line. When a plan leaves a fence open (an edit deletes a
closing fence), the flag stays set for the rest of the file, every later
Task heading is invisible, and the requested task's brief runs to EOF.
The script then reported success: #2436 saw a 177-line task come back as
a 1159-line brief holding tasks 6 through 10, handed to an implementer as
its requirements.

The awk now notes whether a Task heading line appears inside the fence
that is still open at EOF. If one does while the requested task is being
captured, the task's end cannot be found, so task-brief deletes the
partial output and exits 4, naming the line where the fence opened. If
the open fence hides the requested heading itself, it names the fence
before the existing not-found error (exit 3), and suppresses the
"use the English word Task" hint, which would otherwise blame the
plan's English headings for what the fence did.

A fence left open that hides no Task heading changes nothing about the
brief, so it is still written, with a warning on stderr. Real plans do
this: in a corpus of 1,288 plans, refusing on any fence left open at EOF
blocked three correct briefs in two plans, each ending in a stray ``` that
hides no task. With this rule every brief in that corpus matches dev's.
An unclosed fence in a later task leaves an earlier task's brief alone.

The plan path reaches awk through the environment rather than -v, which
would interpret the backslashes of a Windows path as escapes. The fence
rule itself is unchanged, so this composes with #2304's CommonMark fence
tracking: a correct parser still cannot close a fence the author never
closed.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
task-brief ignores Task headings inside fenced code blocks by toggling a
flag on every ``` line. When a plan leaves a fence open (an edit deletes a
closing fence), the flag stays set for the rest of the file, every later
Task heading is invisible, and the requested task's brief runs to EOF.
The script then reported success: #2436 saw a 177-line task come back as
a 1159-line brief holding tasks 6 through 10, handed to an implementer as
its requirements.

The awk now notes whether a Task heading line appears inside the fence
that is still open at EOF. If one does while the requested task is being
captured, the task's end cannot be found, so task-brief deletes the
partial output and exits 4, naming the line where the fence opened. If
the open fence hides the requested heading itself, it names the fence
before the existing not-found error (exit 3), and suppresses the
"use the English word Task" hint, which would otherwise blame the
plan's English headings for what the fence did.

A fence left open that hides no Task heading changes nothing about the
brief, so it is still written, with a warning on stderr. Real plans do
this: in a corpus of 1,288 plans, refusing on any fence left open at EOF
blocked three correct briefs in two plans, each ending in a stray ``` that
hides no task. With this rule every brief in that corpus matches dev's.
An unclosed fence in a later task leaves an earlier task's brief alone.

The plan path reaches awk through the environment rather than -v, which
would interpret the backslashes of a Windows path as escapes. The fence
rule itself is unchanged, so this composes with #2304's CommonMark fence
tracking: a correct parser still cannot close a fence the author never
closed.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): task-brief says when a plan's task headings are not in English</title>
<updated>2026-10-23T03:38:19+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T22:32:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=750ba92008b88850f6ab321706c7f840bbfff503'/>
<id>750ba92008b88850f6ab321706c7f840bbfff503</id>
<content type='text'>
task-brief recognizes only the English word `Task` in a task heading.
writing-plans' template shows `### Task N:` but never says the word is
machine-read, so a model writing a plan in Spanish writes `## Tarea 1:`.
task-brief and task-start then report "task 1 not found in plan-es.md
(no heading matching 'Task 1')", which reads as "this plan has no task 1"
and sends the controller looking for a task that is on line 3 (#2496).

When a plan has no Task headings at all, task-brief now prints, before the
existing not-found line, that task headings must use the English word
"Task" whatever the plan's language, and lists up to five headings shaped
like tasks (`&lt;word&gt; &lt;id-with-a-digit&gt;`). A plan that has Task headings,
just not the requested one, still gets only the not-found line, so asking
for Task 9 of an eight-task plan stays quiet.

This deliberately does not accept other words. Plans commonly carry
`Phase 1`, `Chunk 2` and `Step 1` headings, and a word-agnostic rule
would turn them into tasks. Keeping the word fixed in the plans
themselves is a writing-plans wording change, which needs evals.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
task-brief recognizes only the English word `Task` in a task heading.
writing-plans' template shows `### Task N:` but never says the word is
machine-read, so a model writing a plan in Spanish writes `## Tarea 1:`.
task-brief and task-start then report "task 1 not found in plan-es.md
(no heading matching 'Task 1')", which reads as "this plan has no task 1"
and sends the controller looking for a task that is on line 3 (#2496).

When a plan has no Task headings at all, task-brief now prints, before the
existing not-found line, that task headings must use the English word
"Task" whatever the plan's language, and lists up to five headings shaped
like tasks (`&lt;word&gt; &lt;id-with-a-digit&gt;`). A plan that has Task headings,
just not the requested one, still gets only the not-found line, so asking
for Task 9 of an eight-task plan stays quiet.

This deliberately does not accept other words. Plans commonly carry
`Phase 1`, `Chunk 2` and `Step 1` headings, and a word-agnostic rule
would turn them into tasks. Keeping the word fixed in the plans
themselves is a writing-plans wording change, which needs evals.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): task-brief recognizes alphanumeric task IDs and matches them whole</title>
<updated>2026-10-23T03:38:19+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T22:31:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=f75c01fd9b320060c301e2c6591dfc74a8436f15'/>
<id>f75c01fd9b320060c301e2c6591dfc74a8436f15</id>
<content type='text'>
task-brief only treated `Task` followed by digits as a task heading, and
found the requested task by splicing TASK_NUMBER into a regex followed
by `([^0-9]|$)`. Plans that number tasks by lane (`### Task A1`,
`### Task B2`) could not be extracted at all: `task-brief plan.md A1`
exits 3 "task A1 not found" (#2459). Among 1,288 distinct plans in Jesse's
own repositories, 19 plans have such headings (262 headings, IDs like A1,
M3a, F.2, W0), and none of those tasks could be briefed.

The same splice made the match a prefix match: Task 6 also took a sibling
Task 6b (#2175), Task 1 took Task 1.1 and 1.2, Task 2.1 took Task 201
because `.` is any character, and an ID like `6(` crashed awk (#2405).

A task heading is now `Task` followed by an ID made of letters and digits,
optionally dot-separated, that contains at least one digit. The digit is
what keeps `## Task Overview` or `#### Task notes` from becoming a task
boundary. awk extracts the heading's ID and compares it to TASK_NUMBER as
a whole string, so TASK_NUMBER never reaches awk as a regex.

A deeper Task heading whose ID extends the requested one with a letter or
dot is a sub-task and stays in the parent's brief, as the prefix match
happened to do before: plans in that corpus nest `#### Task 1a` under
`### Task 1`, and a Task 1 brief without its sub-tasks would lose most of
its requirements. A sub-task's own brief ends at its next sibling. Depth
alone is not the test, because plans also drift from `## Task 1` to
`### Task 2`, and those are siblings.

The heading word stays the English literal `Task`, which is what
writing-plans' template uses. Widening it to any word would turn the
`Phase 1`, `Chunk 2` and `Step 1` headings that plans commonly carry
(308, 182 and 56 of them in the same corpus) into tasks.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
task-brief only treated `Task` followed by digits as a task heading, and
found the requested task by splicing TASK_NUMBER into a regex followed
by `([^0-9]|$)`. Plans that number tasks by lane (`### Task A1`,
`### Task B2`) could not be extracted at all: `task-brief plan.md A1`
exits 3 "task A1 not found" (#2459). Among 1,288 distinct plans in Jesse's
own repositories, 19 plans have such headings (262 headings, IDs like A1,
M3a, F.2, W0), and none of those tasks could be briefed.

The same splice made the match a prefix match: Task 6 also took a sibling
Task 6b (#2175), Task 1 took Task 1.1 and 1.2, Task 2.1 took Task 201
because `.` is any character, and an ID like `6(` crashed awk (#2405).

A task heading is now `Task` followed by an ID made of letters and digits,
optionally dot-separated, that contains at least one digit. The digit is
what keeps `## Task Overview` or `#### Task notes` from becoming a task
boundary. awk extracts the heading's ID and compares it to TASK_NUMBER as
a whole string, so TASK_NUMBER never reaches awk as a regex.

A deeper Task heading whose ID extends the requested one with a letter or
dot is a sub-task and stays in the parent's brief, as the prefix match
happened to do before: plans in that corpus nest `#### Task 1a` under
`### Task 1`, and a Task 1 brief without its sub-tasks would lose most of
its requirements. A sub-task's own brief ends at its next sibling. Depth
alone is not the test, because plans also drift from `## Task 1` to
`### Task 2`, and those are siblings.

The heading word stays the English literal `Task`, which is what
writing-plans' template uses. Widening it to any word would turn the
`Phase 1`, `Chunk 2` and `Step 1` headings that plans commonly carry
(308, 182 and 56 of them in the same corpus) into tasks.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): append git's own error line to the no-repo message</title>
<updated>2026-10-23T00:21:52+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-23T00:17:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=8b0eefc87b26530a71f0912af09af023fa3008fc'/>
<id>8b0eefc87b26530a71f0912af09af023fa3008fc</id>
<content type='text'>
sdd-repo ran git with stderr discarded, so every git failure became
"must run from inside the git working tree ... run 'git init'". Where
git refuses a working tree the caller is actually inside (dubious
ownership on another owner's, FAT, network or WSL /mnt/c checkout; git
missing from PATH; the cwd inside .git), that message is false, points
at git init in an existing project, and hides the one line naming the
real fix. dev printed git's fatal, so this was a diagnostic regression.

The shared message stays, and git's first stderr line from whichever
check failed now always follows it as "git said: &lt;line&gt;", with no
per-case branches:

  SDD scripts must run from inside the git working tree ... then rerun.
  git said: fatal: detected dubious ownership in repository at '/r'

Tests: every no-repo assertion now requires the second line (a plain
non-repo dir gives "git said: fatal: not a git repository"), and a new
test simulates dubious ownership with git's GIT_TEST_ASSUME_DIFFERENT_OWNER
knob (no root or second uid needed; it skips if the installed git
ignores the knob).

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
sdd-repo ran git with stderr discarded, so every git failure became
"must run from inside the git working tree ... run 'git init'". Where
git refuses a working tree the caller is actually inside (dubious
ownership on another owner's, FAT, network or WSL /mnt/c checkout; git
missing from PATH; the cwd inside .git), that message is false, points
at git init in an existing project, and hides the one line naming the
real fix. dev printed git's fatal, so this was a diagnostic regression.

The shared message stays, and git's first stderr line from whichever
check failed now always follows it as "git said: &lt;line&gt;", with no
per-case branches:

  SDD scripts must run from inside the git working tree ... then rerun.
  git said: fatal: detected dubious ownership in repository at '/r'

Tests: every no-repo assertion now requires the second line (a plain
non-repo dir gives "git said: fatal: not a git repository"), and a new
test simulates dubious ownership with git's GIT_TEST_ASSUME_DIFFERENT_OWNER
knob (no root or second uid needed; it skips if the installed git
ignores the knob).

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): act on the cwd's working tree only, drop the plan-repo fallback</title>
<updated>2026-10-23T00:21:52+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T23:59:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=0d61007ef6a3a0a870f164a37da14b58f3de192a'/>
<id>0d61007ef6a3a0a870f164a37da14b58f3de192a</id>
<content type='text'>
sdd-repo fell back to the plan file's repository when the current
directory was outside any repository. That made the plugin-cache case
silently succeed somewhere: an agent that cd'd into the skill directory
and passed an absolute plan path got whichever checkout that path
pointed into. With the plan in the main checkout (where writing-plans
leaves it) and execution in a linked worktree, that is the #2429
wrong-worktree bug again, with exit 0. A real session (sdd-cwd-eval
sdd-A-5) took exactly this path and only landed in the right place
because its plan path happened to be the worktree's.

The SDD and executing-plans helpers now pick their repository the way
git does: the current directory's working tree, or DIR when given -C
DIR. Outside any working tree, sdd-workspace, task-brief,
review-package, task-start and task-done all stop with the shared
message and write nothing, even when the plan's absolute path is inside
a repository. sdd-repo no longer takes PLAN_FILE, since the plan has no
say.

The two "outside any repository ... uses the plan's repository" tests
and the task-start/task-done fallback tests become assertions that the
shared message comes out and nothing is written, in the cwd or the
plan's repository.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
sdd-repo fell back to the plan file's repository when the current
directory was outside any repository. That made the plugin-cache case
silently succeed somewhere: an agent that cd'd into the skill directory
and passed an absolute plan path got whichever checkout that path
pointed into. With the plan in the main checkout (where writing-plans
leaves it) and execution in a linked worktree, that is the #2429
wrong-worktree bug again, with exit 0. A real session (sdd-cwd-eval
sdd-A-5) took exactly this path and only landed in the right place
because its plan path happened to be the worktree's.

The SDD and executing-plans helpers now pick their repository the way
git does: the current directory's working tree, or DIR when given -C
DIR. Outside any working tree, sdd-workspace, task-brief,
review-package, task-start and task-done all stop with the shared
message and write nothing, even when the plan's absolute path is inside
a repository. sdd-repo no longer takes PLAN_FILE, since the plan has no
say.

The two "outside any repository ... uses the plan's repository" tests
and the task-start/task-done fallback tests become assertions that the
shared message comes out and nothing is written, in the cwd or the
plan's repository.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): one no-repo message that puts "run from your working tree" first</title>
<updated>2026-10-23T00:21:52+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T23:25:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=de67241e0a8f241b5607f99c3891d5e517e2cf47'/>
<id>de67241e0a8f241b5607f99c3891d5e517e2cf47</id>
<content type='text'>
sdd-repo's no-repository message told every caller to run 'git init'.
That is the right fix for a new project, but the other way to reach it
is standing in the wrong directory, such as the plugin's own skill
directory after reading "from this skill's directory" literally. There,
'git init' would turn the plugin cache into a repository and hide the
real mistake.

task-start and task-done were worse. They still read HEAD and BASE in
the bare cwd while the brief and ledger went through sdd-repo. From a
non-repo cwd with the plan in a repo that has commits, task-start wrote
the brief into the plan's repo, then printed git's fatal plus "HEAD has
no commit yet ... make an initial commit first" and exited 2. task-done
printed git's fatal. review-package in a repo with no commit said
"bad BASE: HEAD~1".

Every helper that can hit this (sdd-workspace, task-brief,
review-package, task-start, task-done) now stops with the same message
from sdd-repo, naming the current directory and offering init-and-commit
only as the new-project case:

  SDD scripts must run from inside the git working tree you're
  executing in, with at least one commit (current directory: &lt;PWD&gt;).
  If this is a new project, run 'git init' and make a first commit,
  then rerun.

sdd-repo gains --with-commit, which also refuses a repository whose HEAD
has no commit. review-package, task-start and task-done pass it because
they need HEAD as a BASE or a review range; sdd-workspace and task-brief
do not, so a brief can still be written right after git init.
task-start and task-done now read HEAD and BASE with git -C in the
repository sdd-repo names. Resolution is otherwise unchanged: the cwd's
repo, else the plan's, else exit 2. sdd-repo is now executable like its
siblings.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
sdd-repo's no-repository message told every caller to run 'git init'.
That is the right fix for a new project, but the other way to reach it
is standing in the wrong directory, such as the plugin's own skill
directory after reading "from this skill's directory" literally. There,
'git init' would turn the plugin cache into a repository and hide the
real mistake.

task-start and task-done were worse. They still read HEAD and BASE in
the bare cwd while the brief and ledger went through sdd-repo. From a
non-repo cwd with the plan in a repo that has commits, task-start wrote
the brief into the plan's repo, then printed git's fatal plus "HEAD has
no commit yet ... make an initial commit first" and exited 2. task-done
printed git's fatal. review-package in a repo with no commit said
"bad BASE: HEAD~1".

Every helper that can hit this (sdd-workspace, task-brief,
review-package, task-start, task-done) now stops with the same message
from sdd-repo, naming the current directory and offering init-and-commit
only as the new-project case:

  SDD scripts must run from inside the git working tree you're
  executing in, with at least one commit (current directory: &lt;PWD&gt;).
  If this is a new project, run 'git init' and make a first commit,
  then rerun.

sdd-repo gains --with-commit, which also refuses a repository whose HEAD
has no commit. review-package, task-start and task-done pass it because
they need HEAD as a BASE or a review range; sdd-workspace and task-brief
do not, so a brief can still be written right after git init.
task-start and task-done now read HEAD and BASE with git -C in the
repository sdd-repo names. Resolution is otherwise unchanged: the cwd's
repo, else the plan's, else exit 2. sdd-repo is now executable like its
siblings.

Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
<entry>
<title>fix(sdd): pick the scripts' repository deliberately, add -C DIR, explain a missing repo</title>
<updated>2026-10-23T00:21:52+00:00</updated>
<author>
<name>Jesse Vincent</name>
<email>jesse@fsck.com</email>
</author>
<published>2026-10-22T22:24:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/superpowers.git/commit/?id=614d80c29a4ad0c0fffb8c49ce5fc5b8afa0bf42'/>
<id>614d80c29a4ad0c0fffb8c49ce5fc5b8afa0bf42</id>
<content type='text'>
The SDD helpers found their repository with a bare
`git rev-parse --show-toplevel` in the caller's cwd, and review-package ran
every git command there too. Three reports trace back to that one line:

- #2429: outside any repository (the skill's own directory in a 7.0
  package has no .git), sdd-workspace fed `cd` an empty path. bash 5.2
  treats that as a no-op and wrote the workspace into the cwd after
  printing git's bare fatal; Git Bash failed with "cd: null directory".
  A controller working on worktree B from worktree A had no way to name B.
- #1799: the only way to aim review-package at a worktree was a
  `cd &lt;worktree&gt; ; review-package ...` compound, which harnesses cannot
  allowlist because the path and BASE change on every run.
- #2242: in a greenfield directory with no repository, task-brief and
  sdd-workspace printed git's fatal and then carried on in the cwd (or
  crashed, depending on bash), review-package said "bad BASE: HEAD~1", and
  task-start printed an empty BASE with exit 0.

A new sdd-repo helper is the single place that picks the repository:
the cwd's working tree (or -C DIR's), exactly as git does. Anywhere else
it stops with exit 2 and one shared message.
sdd-workspace and review-package both use it, so they cannot disagree.
The cwd still wins over the plan's location on purpose: writing-plans
leaves the plan uncommitted in the main checkout, so an executor working
in a linked worktree passes the main checkout's plan path, and its
workspace and commits belong to the worktree. Resolving from PLAN_FILE
first (draft #2439) breaks exactly that flow: review-package then diffs
the main checkout and fails with "empty commit range".

sdd-workspace, task-brief and review-package take an optional leading
`-C DIR` that runs them as if started in DIR, as git -C does, so a caller
can name another worktree in one allowlistable command. Each script
resolves its own directory before the cd, so the documented
`bash scripts/review-package` form from the skill directory keeps
working with -C. PR #1809's version cd's first and then fails to find
sdd-workspace (exit 127) in that form.

task-start now refuses (exit 2) to print a BASE when HEAD has no commit,
instead of printing "base: HEAD" or "base: " with exit 0.

Co-authored-by: citizen204 &lt;citizen204@users.noreply.github.com&gt;
Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The SDD helpers found their repository with a bare
`git rev-parse --show-toplevel` in the caller's cwd, and review-package ran
every git command there too. Three reports trace back to that one line:

- #2429: outside any repository (the skill's own directory in a 7.0
  package has no .git), sdd-workspace fed `cd` an empty path. bash 5.2
  treats that as a no-op and wrote the workspace into the cwd after
  printing git's bare fatal; Git Bash failed with "cd: null directory".
  A controller working on worktree B from worktree A had no way to name B.
- #1799: the only way to aim review-package at a worktree was a
  `cd &lt;worktree&gt; ; review-package ...` compound, which harnesses cannot
  allowlist because the path and BASE change on every run.
- #2242: in a greenfield directory with no repository, task-brief and
  sdd-workspace printed git's fatal and then carried on in the cwd (or
  crashed, depending on bash), review-package said "bad BASE: HEAD~1", and
  task-start printed an empty BASE with exit 0.

A new sdd-repo helper is the single place that picks the repository:
the cwd's working tree (or -C DIR's), exactly as git does. Anywhere else
it stops with exit 2 and one shared message.
sdd-workspace and review-package both use it, so they cannot disagree.
The cwd still wins over the plan's location on purpose: writing-plans
leaves the plan uncommitted in the main checkout, so an executor working
in a linked worktree passes the main checkout's plan path, and its
workspace and commits belong to the worktree. Resolving from PLAN_FILE
first (draft #2439) breaks exactly that flow: review-package then diffs
the main checkout and fails with "empty commit range".

sdd-workspace, task-brief and review-package take an optional leading
`-C DIR` that runs them as if started in DIR, as git -C does, so a caller
can name another worktree in one allowlistable command. Each script
resolves its own directory before the cd, so the documented
`bash scripts/review-package` form from the skill directory keeps
working with -C. PR #1809's version cd's first and then fails to find
sdd-workspace (exit 127) in that form.

task-start now refuses (exit 2) to print a BASE when HEAD has no commit,
instead of printing "base: HEAD" or "base: " with exit 0.

Co-authored-by: citizen204 &lt;citizen204@users.noreply.github.com&gt;
Claude-Session: https://claude.ai/code/session_01SHANcr4A71nzuU9et4Fnba
</pre>
</div>
</content>
</entry>
</feed>
