Add story 60: Status-Based Directory Layout

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Dave
2026-02-20 16:39:41 +00:00
parent 5375be27b1
commit b76b5df8c9

View File

@@ -0,0 +1,74 @@
---
name: Status-Based Directory Layout
test_plan: pending
---
# Story 60: Status-Based Directory Layout
## User Story
As a developer, I want work items organized by pipeline status rather than by type, with a unified naming convention, so the directory structure reflects what stage everything is at.
## Current Layout (mixed)
```
.story_kit/
current/
stories/
upcoming/
archived/
bugs/
archive/
spikes/
specs/
```
## New Layout
```
.story_kit/
upcoming/ ← all work items waiting to start
current/ ← being coded
qa/ ← being reviewed by QA agent
merge/ ← being merged to master
archived/ ← done
specs/ ← long-lived project info (not a work item)
worktrees/ ← agent worktrees (unchanged)
project.toml ← config (unchanged)
```
## Naming Convention
All work items use: `{number}_{type}_{slug}.md`
```
upcoming/57_story_foo_bar_blah.md
upcoming/58_spike_a_b_c.md
upcoming/59_bug_flappapa.md
```
Types: `story`, `bug`, `spike`. The number is the primary identifier, auto-incremented across all types. You say "story 57", "bug 59", etc.
## Acceptance Criteria
- [ ] Migrate existing `stories/upcoming/``upcoming/`, renaming files to include `_story_` type prefix
- [ ] Migrate existing `stories/archived/``archived/`, renaming files to include `_story_` type prefix
- [ ] Migrate existing `bugs/``archived/` (for closed) or `upcoming/` (for open), renaming to include `_bug_` type prefix
- [ ] Remove old `stories/`, `bugs/` directories
- [ ] `create_story`, `create_bug` MCP tools use the new naming convention and write to `upcoming/`
- [ ] `start_agent` moves from `upcoming/` to `current/`
- [ ] `accept_story` and `close_bug` move from `current/` (or `merge/`) to `archived/`
- [ ] `find_story_file()` and all path references updated to search by status dirs
- [ ] `next_story_number()` scans all status dirs for the highest number across all types
- [ ] All existing tests updated for new paths
- [ ] Integration test: full lifecycle through upcoming → current → archived
## Supersedes
- Story 51 (Deterministic Spike Lifecycle) — folded into this story's naming convention
## Out of Scope
- QA and merge pipeline automation (just create the empty directories)
- Frontend changes to reflect new layout
- Spike-specific MCP tools (create_spike, archive_spike) — follow-up