Migrate Kanban Skill
Purpose
Transforms a flat tasks/ directory (e.g., tasks/01-task.md, tasks/02-task.md) into the state-based V6 Kanban lifecycle structure:
tasks/backlog/— Open / unstarted taskstasks/in-progress/— Currently being worked ontasks/qa/— Awaiting review / quality assurancetasks/completed/— Finished taskstasks/archive/— Milestone-compacted historical tasks
Workflow
- Create the 5 Kanban directories if they do not already exist:
mkdir -p tasks/backlog tasks/in-progress tasks/qa tasks/completed tasks/archive
- Scan all
.mdfiles in the flattasks/root (excluding the Kanban subdirectories):
find tasks/ -maxdepth 1 -type f -name "*.md" | sort
Classify each file by reading its frontmatter or first line:
- If the file contains
Status: open(or**Status:** open), move it totasks/backlog/. - If the file contains
Status: closed(or**Status:** closed), move it totasks/completed/. - If no status is found, default to
tasks/backlog/.
- If the file contains
Move the files using
git mvto preserve history:
for f in tasks/*.md; do
[ -e "$f" ] || continue
[ "$f" = "tasks/README.md" ] && continue
if grep -qi "Status: open" "$f" 2>/dev/null; then
git mv "$f" tasks/backlog/
elif grep -qi "Status: closed" "$f" 2>/dev/null; then
git mv "$f" tasks/completed/
else
git mv "$f" tasks/backlog/
fi
done
- Verify the migration:
echo "=== Backlog ===" && ls tasks/backlog/
echo "=== Completed ===" && ls tasks/completed/
- Update AGENTS.md to reference the Kanban directory structure in the "Core File Locations" and "Documentation Sync Rules" sections.
Post-Migration
After running this skill, the flat tasks/ directory should be empty (except for the 5 Kanban subdirectories). All existing task history is preserved via git mv.