Compare commits

..

1 Commits

Author SHA1 Message Date
Drew Ritter
cb6bdf9dd3 Fix shell lint baseline warnings 2026-06-02 15:35:26 -07:00
17 changed files with 47 additions and 87 deletions

View File

@@ -12,17 +12,14 @@ add a comment or reaction to the existing one instead.
- [ ] I searched existing issues and this is not a duplicate - [ ] I searched existing issues and this is not a duplicate
## Environment (required) ## Environment
<!-- Required. We assume an agent filed this report — tell us which one and
where it ran. We weigh reports by what produced them. -->
| Field | Value | | Field | Value |
|-------|-------| |-------|-------|
| Superpowers version | | | Superpowers version | |
| Harness (Claude Code, Cursor, etc.) | | | Harness (Claude Code, Cursor, etc.) | |
| Harness version | | | Harness version | |
| Your model + version | | | Model | |
| All plugins installed | |
| OS + shell | | | OS + shell | |
## Is this a Superpowers issue or a platform issue? ## Is this a Superpowers issue or a platform issue?

View File

@@ -30,18 +30,5 @@ progress, and some were intentionally declined.
of project? If this is specific to your domain, workflow, or a of project? If this is specific to your domain, workflow, or a
third-party tool, it may belong as its own plugin instead. --> third-party tool, it may belong as its own plugin instead. -->
## Environment (required)
<!-- Required. We assume an agent wrote this request — tell us which one and
where it ran. We weigh proposals reasoned from documentation differently
than ones grounded in a real session where the problem actually came up. -->
| Field | Value |
|-------|-------|
| Superpowers version | |
| Harness (Claude Code, Cursor, etc.) | |
| Harness version | |
| Your model + version | |
| All plugins installed | |
## Context ## Context
<!-- Optional: the workflow where you hit this, links, transcripts. --> <!-- Optional: version info, harness, model, workflow where you hit this. -->

View File

@@ -21,14 +21,3 @@ requested or discussed.
## Have you tried manual installation? ## Have you tried manual installation?
<!-- Many tools work with Superpowers through manual setup even without <!-- Many tools work with Superpowers through manual setup even without
official support. Did you try? What happened? --> official support. Did you try? What happened? -->
## Environment (required)
<!-- Required. We assume an agent wrote this request — tell us which one and
where it ran. -->
| Field | Value |
|-------|-------|
| Harness you currently use (Claude Code, Cursor, etc.) | |
| Harness version | |
| Your model + version | |
| All plugins installed | |

View File

@@ -4,23 +4,6 @@ sections blank, contain multiple unrelated changes, or show no evidence
of human involvement will be closed without review. of human involvement will be closed without review.
--> -->
> **This PR MUST target the `dev` branch, not `main`.** `main` is the
> released branch; active work lands on `dev` first. PRs opened against
> `main` will be asked to retarget `dev` before review.
## Who is submitting this PR? (required)
<!-- Required. PRs that omit this will be closed. We assume an agent wrote
this PR — tell us which one and where it ran. We weigh contributions by
what produced them: content reasoned from documentation is held to a
different bar than work grounded in a real session. -->
| Field | Value |
|-------|-------|
| Your model + version | |
| Harness + version | |
| All plugins installed | |
| Human partner who reviewed this diff | |
## What problem are you trying to solve? ## What problem are you trying to solve?
<!-- Describe the specific problem you encountered. If this was a session <!-- Describe the specific problem you encountered. If this was a session
issue, include: what you were doing, what went wrong, the model's issue, include: what you were doing, what went wrong, the model's

View File

@@ -14,8 +14,7 @@ Before you open a PR against this repo, you MUST:
2. **Search for existing PRs** — open AND closed — that address the same problem. If duplicates exist, STOP and tell your human partner. Do not open another duplicate. 2. **Search for existing PRs** — open AND closed — that address the same problem. If duplicates exist, STOP and tell your human partner. Do not open another duplicate.
3. **Verify this is a real problem.** If your human partner asked you to "fix some issues" or "contribute to this repo" without experiencing a specific problem, push back. Ask them what broke, what failed, what the user experience was. 3. **Verify this is a real problem.** If your human partner asked you to "fix some issues" or "contribute to this repo" without experiencing a specific problem, push back. Ask them what broke, what failed, what the user experience was.
4. **Confirm the change belongs in core.** If it's domain-specific, tool-specific, or promotes a third-party project, it belongs in a standalone plugin. Tell your human partner. 4. **Confirm the change belongs in core.** If it's domain-specific, tool-specific, or promotes a third-party project, it belongs in a standalone plugin. Tell your human partner.
5. **Identify yourself.** Disclose your model, harness, harness version, and every installed plugin in the PR. Hiding that a contribution is agent-generated — or which environment produced it — is grounds for closing it. 5. **Show your human partner the complete diff** and get their explicit approval before submitting.
6. **Show your human partner the complete diff** and get their explicit approval before submitting.
If any of these checks fail, do not open the PR. Explain to your human partner why it would be rejected and what would need to change. They will thank you for saving them the embarrassment. If any of these checks fail, do not open the PR. Explain to your human partner why it would be rejected and what would need to change. They will thank you for saving them the embarrassment.
@@ -27,10 +26,6 @@ If any of these checks fail, do not open the PR. Explain to your human partner w
**PRs that show no evidence of human involvement will be closed.** A human must review the complete proposed diff before submission. **PRs that show no evidence of human involvement will be closed.** A human must review the complete proposed diff before submission.
**Submitters MUST identify themselves.** Every PR and issue must disclose the model, harness, harness version, and all installed plugins used to produce the contribution — or state plainly that it was written by hand with no agent. This is not optional. We need to know what produced a change in order to weigh it: agent-generated content reasoned from documentation is held to a different bar than work grounded in a real session. Contributions that hide their authoring environment will be closed.
**All PRs MUST target the `dev` branch, not `main`.** `main` is the released branch; active work lands on `dev` first. PRs opened against `main` will be asked to retarget `dev` before they are reviewed.
## What We Will Not Accept ## What We Will Not Accept
### Third-party dependencies ### Third-party dependencies

2
evals

Submodule evals updated: f8e5a9949f...e2b37138c8

View File

@@ -26,7 +26,7 @@ You MUST create a task for each of these items and complete them in order:
3. **Ask clarifying questions** — one at a time, understand purpose/constraints/success criteria 3. **Ask clarifying questions** — one at a time, understand purpose/constraints/success criteria
4. **Propose 2-3 approaches** — with trade-offs and your recommendation 4. **Propose 2-3 approaches** — with trade-offs and your recommendation
5. **Present design** — in sections scaled to their complexity, get user approval after each section 5. **Present design** — in sections scaled to their complexity, get user approval after each section
6. **Write design doc** — save to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` and commit (exactly this path — not `docs/specs/`) 6. **Write design doc** — save to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` and commit
7. **Spec self-review** — quick inline check for placeholders, contradictions, ambiguity, scope (see below) 7. **Spec self-review** — quick inline check for placeholders, contradictions, ambiguity, scope (see below)
8. **User reviews written spec** — ask user to review the spec file before proceeding 8. **User reviews written spec** — ask user to review the spec file before proceeding
9. **Transition to implementation** — invoke writing-plans skill to create implementation plan 9. **Transition to implementation** — invoke writing-plans skill to create implementation plan
@@ -109,7 +109,7 @@ digraph brainstorming {
**Documentation:** **Documentation:**
- Write the validated design (spec) to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` - Write the validated design (spec) to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md`
- (An explicit user instruction overrides this default; an existing differently-named docs directory does not) - (User preferences for spec location override this default)
- Use elements-of-style:writing-clearly-and-concisely skill if available - Use elements-of-style:writing-clearly-and-concisely skill if available
- Commit the design document to git - Commit the design document to git

View File

@@ -97,7 +97,7 @@ if [[ -f "$PID_FILE" ]]; then
rm -f "$PID_FILE" rm -f "$PID_FILE"
fi fi
cd "$SCRIPT_DIR" cd "$SCRIPT_DIR" || exit
# Resolve the harness PID (grandparent of this script). # Resolve the harness PID (grandparent of this script).
# $PPID is the ephemeral shell the harness spawned to run us — it dies # $PPID is the ephemeral shell the harness spawned to run us — it dies
@@ -135,7 +135,7 @@ disown "$SERVER_PID" 2>/dev/null
echo "$SERVER_PID" > "$PID_FILE" echo "$SERVER_PID" > "$PID_FILE"
# Wait for server-started message (check log file) # Wait for server-started message (check log file)
for i in {1..50}; do for _ in {1..50}; do
if grep -q "server-started" "$LOG_FILE" 2>/dev/null; then if grep -q "server-started" "$LOG_FILE" 2>/dev/null; then
# Verify server is still alive after a short window (catches process reapers) # Verify server is still alive after a short window (catches process reapers)
alive="true" alive="true"

View File

@@ -23,7 +23,7 @@ if [[ -f "$PID_FILE" ]]; then
kill "$pid" 2>/dev/null || true kill "$pid" 2>/dev/null || true
# Wait for graceful shutdown (up to ~2s) # Wait for graceful shutdown (up to ~2s)
for i in {1..20}; do for _ in {1..20}; do
if ! kill -0 "$pid" 2>/dev/null; then if ! kill -0 "$pid" 2>/dev/null; then
break break
fi fi

View File

@@ -16,7 +16,7 @@ Load plan, review critically, execute all tasks, report when complete.
## The Process ## The Process
### Step 1: Load and Review Plan ### Step 1: Load and Review Plan
1. Read plan file, and the spec it cites in its `**Spec:**` header (plans reference requirements rather than restating them) 1. Read plan file
2. Review critically - identify any questions or concerns about the plan 2. Review critically - identify any questions or concerns about the plan
3. If concerns: Raise them with your human partner before starting 3. If concerns: Raise them with your human partner before starting
4. If no concerns: Create todos for the plan items and proceed 4. If no concerns: Create todos for the plan items and proceed

View File

@@ -86,10 +86,6 @@ digraph process {
} }
``` ```
## Spec Context
If the plan's header cites a spec (`**Spec:** <path>`), read it once during plan extraction. Plans reference requirements rather than restating them — when a task cites a spec section, paste that section's text into the implementer and spec-reviewer prompts along with the task text. Implementer subagents never read the spec file themselves; the spec reviewer may additionally read it at the cited path (its prompt says so).
## Model Selection ## Model Selection
Use the least powerful model that can handle each role to conserve cost and increase speed. Use the least powerful model that can handle each role to conserve cost and increase speed.

View File

@@ -12,8 +12,6 @@ Subagent (general-purpose):
[FULL TEXT of task from plan - paste it here, don't make subagent read file] [FULL TEXT of task from plan - paste it here, don't make subagent read file]
[If the task cites spec sections, paste the cited sections' text here too]
## Context ## Context
[Scene-setting: where this fits, dependencies, architectural context] [Scene-setting: where this fits, dependencies, architectural context]

View File

@@ -12,7 +12,7 @@ Subagent (general-purpose):
## What Was Requested ## What Was Requested
[FULL TEXT of task requirements, including the text of any spec sections the task cites] [FULL TEXT of task requirements]
## What Implementer Claims They Built ## What Implementer Claims They Built
@@ -28,7 +28,7 @@ Subagent (general-purpose):
git diff [BASE_SHA]..[HEAD_SHA] git diff [BASE_SHA]..[HEAD_SHA]
``` ```
Only read files in this diff. Do not crawl the broader codebase. (One exception: if the requirements cite a spec document, you may read that spec at its cited path.) Only read files in this diff. Do not crawl the broader codebase.
## Read-Only Review ## Read-Only Review

View File

@@ -7,18 +7,16 @@ description: Use when you have a spec or requirements for a multi-step task, bef
## Overview ## Overview
Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to execute: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits. Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to know: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well. Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well.
**Plans reference the spec; they never restate, paraphrase, or summarize it.** The spec owns the WHAT and WHY — requirements, acceptance criteria, design decisions; the plan owns the HOW — tasks, files, code, commands. Cite it by path in the header and by section where a task needs context. Reference discipline never means skipping the spec: if brainstorming produced one, it exists and the plan cites it. No Placeholders still requires repeating code and commands WITHIN the plan; copying FROM the spec is different: a step that needs a requirement's prose is under-specified — turn it into a concrete action. Snapshotting spec text into the plan hides drift, not prevents it. "Zero context" means each step is mechanically executable, not that the plan repeats the spec.
**Announce at start:** "I'm using the writing-plans skill to create the implementation plan." **Announce at start:** "I'm using the writing-plans skill to create the implementation plan."
**Context:** If working in an isolated worktree, it should have been created via the `superpowers:using-git-worktrees` skill at execution time. **Context:** If working in an isolated worktree, it should have been created via the `superpowers:using-git-worktrees` skill at execution time.
**Save plans to:** `docs/superpowers/plans/YYYY-MM-DD-<feature-name>.md` **Save plans to:** `docs/superpowers/plans/YYYY-MM-DD-<feature-name>.md`
- (An explicit user instruction overrides this default; an existing differently-named docs directory does not) - (User preferences for plan location override this default)
## Scope Check ## Scope Check
@@ -55,8 +53,6 @@ This structure informs the task decomposition. Each task should produce self-con
**Goal:** [One sentence describing what this builds] **Goal:** [One sentence describing what this builds]
**Spec:** [Path to the spec doc, e.g. `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` — requirements and design decisions live there; do not restate them here. Only if no spec doc exists (requirements arrived conversationally; brainstorming never ran): write "none — requirements:" and state them once here, not per task]
**Architecture:** [2-3 sentences about approach] **Architecture:** [2-3 sentences about approach]
**Tech Stack:** [Key technologies/libraries] **Tech Stack:** [Key technologies/libraries]

View File

@@ -7,7 +7,8 @@ run_claude() {
local prompt="$1" local prompt="$1"
local timeout="${2:-60}" local timeout="${2:-60}"
local allowed_tools="${3:-}" local allowed_tools="${3:-}"
local output_file=$(mktemp) local output_file
output_file="$(mktemp)"
# Build command as an argv array so timeout wraps claude directly. # Build command as an argv array so timeout wraps claude directly.
local cmd=(claude -p "$prompt") local cmd=(claude -p "$prompt")
@@ -74,7 +75,8 @@ assert_count() {
local expected="$3" local expected="$3"
local test_name="${4:-test}" local test_name="${4:-test}"
local actual=$(echo "$output" | grep -c "$pattern" || echo "0") local actual
actual="$(echo "$output" | grep -c "$pattern" || true)"
if [ "$actual" -eq "$expected" ]; then if [ "$actual" -eq "$expected" ]; then
echo " [PASS] $test_name (found $actual instances)" echo " [PASS] $test_name (found $actual instances)"
@@ -98,8 +100,10 @@ assert_order() {
local test_name="${4:-test}" local test_name="${4:-test}"
# Get line numbers where patterns appear # Get line numbers where patterns appear
local line_a=$(echo "$output" | grep -n "$pattern_a" | head -1 | cut -d: -f1) local line_a
local line_b=$(echo "$output" | grep -n "$pattern_b" | head -1 | cut -d: -f1) local line_b
line_a="$(echo "$output" | grep -n "$pattern_a" | head -1 | cut -d: -f1 || true)"
line_b="$(echo "$output" | grep -n "$pattern_b" | head -1 | cut -d: -f1 || true)"
if [ -z "$line_a" ]; then if [ -z "$line_a" ]; then
echo " [FAIL] $test_name: pattern A not found: $pattern_a" echo " [FAIL] $test_name: pattern A not found: $pattern_a"
@@ -125,7 +129,8 @@ assert_order() {
# Create a temporary test project directory # Create a temporary test project directory
# Usage: test_project=$(create_test_project) # Usage: test_project=$(create_test_project)
create_test_project() { create_test_project() {
local test_dir=$(mktemp -d) local test_dir
test_dir="$(mktemp -d)"
echo "$test_dir" echo "$test_dir"
} }

View File

@@ -37,7 +37,10 @@ TEST_PROJECT=$(create_test_project)
echo "Test project: $TEST_PROJECT" echo "Test project: $TEST_PROJECT"
# Trap to cleanup # Trap to cleanup
trap "cleanup_test_project $TEST_PROJECT" EXIT cleanup_integration_test_project() {
cleanup_test_project "$TEST_PROJECT"
}
trap cleanup_integration_test_project EXIT
# Set up minimal Node.js project # Set up minimal Node.js project
cd "$TEST_PROJECT" cd "$TEST_PROJECT"
@@ -164,12 +167,19 @@ PLUGIN_DIR=$(cd "$SCRIPT_DIR/../.." && pwd)
# other concurrent claude sessions. # other concurrent claude sessions.
echo "Running Claude (plugin-dir: $PLUGIN_DIR, cwd: $TEST_PROJECT)..." echo "Running Claude (plugin-dir: $PLUGIN_DIR, cwd: $TEST_PROJECT)..."
echo "================================================================================" echo "================================================================================"
cd "$TEST_PROJECT" && timeout 1800 claude -p "$PROMPT" --plugin-dir "$PLUGIN_DIR" --allowed-tools=all --permission-mode bypassPermissions 2>&1 | tee "$OUTPUT_FILE" || { set +e
(
cd "$TEST_PROJECT" &&
timeout 1800 claude -p "$PROMPT" --plugin-dir "$PLUGIN_DIR" --allowed-tools=all --permission-mode bypassPermissions
) 2>&1 | tee "$OUTPUT_FILE"
execution_status=$?
set -e
if [[ "$execution_status" -ne 0 ]]; then
echo "" echo ""
echo "================================================================================" echo "================================================================================"
echo "EXECUTION FAILED (exit code: $?)" echo "EXECUTION FAILED (exit code: $execution_status)"
exit 1 exit 1
} fi
echo "================================================================================" echo "================================================================================"
echo "" echo ""

View File

@@ -47,16 +47,20 @@ assert_not_contains() {
echo "=== Worktree Path Policy Test ===" echo "=== Worktree Path Policy Test ==="
echo "" echo ""
assert_not_contains "$USING_SKILL" "~/.config/superpowers/worktrees" "using-git-worktrees does not mention old global path" # Intentionally search for the literal legacy path, not the current user's home.
# shellcheck disable=SC2088
legacy_global_worktree_path="~/.config/superpowers/worktrees"
assert_not_contains "$USING_SKILL" "$legacy_global_worktree_path" "using-git-worktrees does not mention old global path"
assert_not_contains "$USING_SKILL" "global legacy" "using-git-worktrees does not use unclear global legacy shorthand" assert_not_contains "$USING_SKILL" "global legacy" "using-git-worktrees does not use unclear global legacy shorthand"
assert_not_contains "$USING_SKILL" "Global path" "using-git-worktrees has no global path quick-reference row" assert_not_contains "$USING_SKILL" "Global path" "using-git-worktrees has no global path quick-reference row"
assert_contains "$USING_SKILL" 'default to `.worktrees/` at the project root' "using-git-worktrees defaults new manual worktrees to .worktrees/" assert_contains "$USING_SKILL" 'default to `.worktrees/` at the project root' "using-git-worktrees defaults new manual worktrees to .worktrees/"
assert_not_contains "$FINISHING_SKILL" "~/.config/superpowers/worktrees" "finishing-a-development-branch does not treat old global path as owned" assert_not_contains "$FINISHING_SKILL" "$legacy_global_worktree_path" "finishing-a-development-branch does not treat old global path as owned"
assert_contains "$FINISHING_SKILL" '`.worktrees/` or `worktrees/`' "finishing-a-development-branch keeps project-local cleanup ownership" assert_contains "$FINISHING_SKILL" '`.worktrees/` or `worktrees/`' "finishing-a-development-branch keeps project-local cleanup ownership"
assert_not_contains "$ROTOTILL_SPEC" "~/.config/superpowers/worktrees" "rototill spec does not preserve old global path policy" assert_not_contains "$ROTOTILL_SPEC" "$legacy_global_worktree_path" "rototill spec does not preserve old global path policy"
assert_not_contains "$ROTOTILL_PLAN" "~/.config/superpowers/worktrees" "rototill plan does not preserve old global path policy" assert_not_contains "$ROTOTILL_PLAN" "$legacy_global_worktree_path" "rototill plan does not preserve old global path policy"
assert_not_contains "$ROTOTILL_PLAN" "legacy path compat" "rototill plan does not advertise legacy path compatibility" assert_not_contains "$ROTOTILL_PLAN" "legacy path compat" "rototill plan does not advertise legacy path compatibility"
echo "" echo ""