@pennyfarthing/core 10.0.2 → 10.0.3
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.
- package/README.md +287 -0
- package/package.json +30 -44
- package/packages/core/dist/cli/commands/doctor-file-layout.test.d.ts +13 -0
- package/packages/core/dist/cli/commands/doctor-file-layout.test.d.ts.map +1 -0
- package/packages/core/dist/cli/commands/doctor-file-layout.test.js +234 -0
- package/packages/core/dist/cli/commands/doctor-file-layout.test.js.map +1 -0
- package/{dist → packages/core/dist}/cli/commands/doctor.d.ts +8 -0
- package/{dist → packages/core/dist}/cli/commands/doctor.d.ts.map +1 -1
- package/{dist → packages/core/dist}/cli/commands/doctor.js +224 -3
- package/packages/core/dist/cli/commands/doctor.js.map +1 -0
- package/{dist → packages/core/dist}/cli/commands/e2e-fresh-install.test.js +1 -1
- package/{dist → packages/core/dist}/cli/commands/e2e-fresh-install.test.js.map +1 -1
- package/{dist → packages/core/dist}/cli/commands/e2e-upgrade.test.js +1 -1
- package/{dist → packages/core/dist}/cli/commands/e2e-upgrade.test.js.map +1 -1
- package/packages/core/dist/cli/commands/hooks-consolidation.test.d.ts +19 -0
- package/packages/core/dist/cli/commands/hooks-consolidation.test.d.ts.map +1 -0
- package/packages/core/dist/cli/commands/hooks-consolidation.test.js +358 -0
- package/packages/core/dist/cli/commands/hooks-consolidation.test.js.map +1 -0
- package/{dist → packages/core/dist}/cli/commands/update.d.ts.map +1 -1
- package/{dist → packages/core/dist}/cli/commands/update.js +53 -1
- package/{dist → packages/core/dist}/cli/commands/update.js.map +1 -1
- package/{dist → packages/core/dist}/cli/utils/settings.d.ts.map +1 -1
- package/{dist → packages/core/dist}/cli/utils/settings.js +24 -0
- package/packages/core/dist/cli/utils/settings.js.map +1 -0
- package/{dist → packages/core/dist}/cli/utils/themes.d.ts +1 -0
- package/packages/core/dist/cli/utils/themes.d.ts.map +1 -0
- package/{dist → packages/core/dist}/cli/utils/themes.js.map +1 -1
- package/pennyfarthing-dist/agents/sm-setup.md +4 -4
- package/pennyfarthing-dist/agents/sm.md +8 -1
- package/pennyfarthing-dist/guides/bell-mode.md +65 -0
- package/pennyfarthing-dist/guides/benchmarks.md +62 -0
- package/pennyfarthing-dist/guides/bikelane.md +86 -0
- package/pennyfarthing-dist/guides/prime.md +72 -0
- package/pennyfarthing-dist/guides/reflector.md +59 -0
- package/pennyfarthing-dist/guides/relay-mode.md +53 -0
- package/pennyfarthing-dist/guides/tirepump.md +54 -0
- package/pennyfarthing-dist/personas/themes/battlestar-galactica.yaml +59 -58
- package/pennyfarthing-dist/personas/themes/blade-runner.yaml +10 -10
- package/pennyfarthing-dist/personas/themes/doctor-who.yaml +10 -10
- package/pennyfarthing-dist/personas/themes/dune.yaml +64 -69
- package/pennyfarthing-dist/personas/themes/firefly.yaml +60 -73
- package/pennyfarthing-dist/personas/themes/game-of-thrones.yaml +60 -69
- package/pennyfarthing-dist/personas/themes/harry-potter.yaml +59 -73
- package/pennyfarthing-dist/personas/themes/hitchhikers-guide.yaml +45 -57
- package/pennyfarthing-dist/personas/themes/mad-max.yaml +5 -11
- package/pennyfarthing-dist/personas/themes/princess-bride.yaml +53 -63
- package/pennyfarthing-dist/personas/themes/sandman.yaml +59 -59
- package/pennyfarthing-dist/personas/themes/the-matrix.yaml +61 -62
- package/pennyfarthing-dist/personas/themes/west-wing.yaml +8 -9
- package/pennyfarthing-dist/scripts/core/agent-session.sh +0 -0
- package/pennyfarthing-dist/scripts/core/check-context.sh +0 -0
- package/pennyfarthing-dist/scripts/core/handoff-marker.sh +0 -0
- package/pennyfarthing-dist/scripts/core/phase-check-start.sh +0 -0
- package/pennyfarthing-dist/scripts/core/prime.sh +0 -0
- package/pennyfarthing-dist/scripts/cyclist/is-cyclist.sh +0 -0
- package/pennyfarthing-dist/scripts/git/create-feature-branches.sh +0 -0
- package/pennyfarthing-dist/scripts/git/git-status-all.sh +0 -0
- package/pennyfarthing-dist/scripts/git/install-git-hooks.sh +0 -0
- package/pennyfarthing-dist/scripts/git/release.sh +0 -0
- package/pennyfarthing-dist/scripts/git/worktree-manager.sh +0 -0
- package/pennyfarthing-dist/scripts/health/drift-detection.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/bell-mode-hook.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/context-circuit-breaker.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/context-warning.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/cyclist-pretooluse-hook.sh +32 -0
- package/pennyfarthing-dist/scripts/hooks/otel-auto-config.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/post-merge.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/pre-commit.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/pre-edit-check.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/pre-push.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/question-reflector-check.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/question_reflector_check.py +0 -0
- package/pennyfarthing-dist/scripts/hooks/schema-validation.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/session-start.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/session-stop.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/sprint-yaml-validation.sh +0 -0
- package/pennyfarthing-dist/scripts/hooks/welcome-hook.sh +0 -0
- package/pennyfarthing-dist/scripts/jira/create-jira-epic.sh +12 -91
- package/pennyfarthing-dist/scripts/jira/create-jira-story.sh +11 -86
- package/pennyfarthing-dist/scripts/jira/jira-claim-story.sh +0 -0
- package/pennyfarthing-dist/scripts/jira/jira-reconcile.sh +11 -255
- package/pennyfarthing-dist/scripts/jira/jira-sync-story.sh +0 -0
- package/pennyfarthing-dist/scripts/jira/sync-epic-jira.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/background-tasks.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/checkpoint.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/common.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/file-lock.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/logging.sh +0 -0
- package/pennyfarthing-dist/scripts/lib/retry.sh +0 -0
- package/pennyfarthing-dist/scripts/maintenance/migrate-theme-schema.mjs +0 -0
- package/pennyfarthing-dist/scripts/maintenance/sidecar-health.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/add-short-names.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/add_short_names.py +0 -0
- package/pennyfarthing-dist/scripts/misc/backlog.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/check-status.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/find-related-work.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/generate-skill-docs.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/log-skill-usage.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/migrate-bmad-workflow.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/migrate_bmad_workflow.py +0 -0
- package/pennyfarthing-dist/scripts/misc/repo-scan.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/repo-utils.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/run-ci.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/run-timestamp.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/session-cleanup.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/skill-usage-report.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/statusline.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/uninstall.sh +0 -0
- package/pennyfarthing-dist/scripts/misc/validate-subagent-frontmatter.sh +0 -0
- package/pennyfarthing-dist/scripts/portraits/generate-portraits.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/archive-story.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/available-stories.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/check-story.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/get-epic-field.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/get-story-field.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/list-future.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/new-sprint.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/promote-epic.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/sprint-common.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/sprint-info.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/sprint-metrics.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/sprint-status.sh +0 -0
- package/pennyfarthing-dist/scripts/sprint/validate-sprint-yaml.sh +0 -0
- package/pennyfarthing-dist/scripts/story/create-story.sh +0 -0
- package/pennyfarthing-dist/scripts/story/size-story.sh +0 -0
- package/pennyfarthing-dist/scripts/story/story-template.sh +0 -0
- package/pennyfarthing-dist/scripts/test/ensure-swebench-data.sh +0 -0
- package/pennyfarthing-dist/scripts/test/swebench-judge.py +0 -0
- package/pennyfarthing-dist/scripts/test/test-cache.sh +0 -0
- package/pennyfarthing-dist/scripts/test/test-setup.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/check.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/dev-story-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/epics-and-stories-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/handoff-phase-update.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/implementation-readiness-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/migrate-bmad-workflow.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/prd-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/project-context-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/test-character-voice.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/test-drift-detection.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/test-post-merge-hook.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/test-session-checkpoint.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/test-solo-command.sh +0 -0
- package/pennyfarthing-dist/scripts/tests/ux-design-workflow-import.test.sh +0 -0
- package/pennyfarthing-dist/scripts/theme/compute-theme-tiers.sh +0 -0
- package/pennyfarthing-dist/scripts/theme/compute_theme_tiers.py +0 -0
- package/pennyfarthing-dist/scripts/theme/list-themes.sh +0 -0
- package/pennyfarthing-dist/scripts/theme/update-theme-tiers.sh +0 -0
- package/pennyfarthing-dist/scripts/validation/validate-agent-schema.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/check.py +0 -0
- package/pennyfarthing-dist/scripts/workflow/check.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/complete-step.py +0 -0
- package/pennyfarthing-dist/scripts/workflow/finish-story.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/fix-session-phase.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/get-workflow-type.py +0 -0
- package/pennyfarthing-dist/scripts/workflow/get-workflow-type.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/list-workflows.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/phase-owner.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/resume-workflow.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/show-workflow.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/start-workflow.sh +0 -0
- package/pennyfarthing-dist/scripts/workflow/workflow-status.sh +0 -0
- package/pennyfarthing-dist/skills/jira/SKILL.md +107 -408
- package/pennyfarthing-dist/skills/sprint/scripts/archive-story.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/available-stories.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/check-story.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/create-jira-epic.sh +17 -95
- package/pennyfarthing-dist/skills/sprint/scripts/new-sprint.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/promote-epic.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/sprint-info.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/sprint-status.sh +0 -0
- package/pennyfarthing-dist/skills/sprint/scripts/sync-epic-jira.sh +20 -90
- package/pennyfarthing-dist/skills/story/scripts/create-story.sh +0 -0
- package/pennyfarthing-dist/skills/story/scripts/size-story.sh +0 -0
- package/pennyfarthing-dist/skills/story/scripts/story-template.sh +0 -0
- package/pennyfarthing-dist/skills/workflow/scripts/list-workflows.sh +0 -0
- package/pennyfarthing-dist/skills/workflow/scripts/resume-workflow.sh +0 -0
- package/pennyfarthing-dist/skills/workflow/scripts/show-workflow.sh +0 -0
- package/pennyfarthing-dist/skills/workflow/scripts/start-workflow.sh +0 -0
- package/pennyfarthing-dist/skills/workflow/scripts/workflow-status.sh +0 -0
- package/pennyfarthing-dist/templates/settings.local.json.template +9 -1
- package/pennyfarthing_scripts/README.md +66 -0
- package/pennyfarthing_scripts/__init__.py +17 -0
- package/pennyfarthing_scripts/__pycache__/__init__.cpython-311.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/config.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/hooks.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/jira.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/jira_bidirectional_sync.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/jira_epic_creation.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/jira_sync.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/jira_sync_story.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/output.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/patch_mode.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/pretooluse_hook.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/schema_validation_hook.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/sprint.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/workflow.cpython-311.pyc +0 -0
- package/pennyfarthing_scripts/__pycache__/workflow.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/bellmode_hook.py +154 -0
- package/pennyfarthing_scripts/brownfield/__init__.py +35 -0
- package/pennyfarthing_scripts/brownfield/__main__.py +7 -0
- package/pennyfarthing_scripts/brownfield/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/brownfield/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/brownfield/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/brownfield/__pycache__/discover.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/brownfield/cli.py +131 -0
- package/pennyfarthing_scripts/brownfield/discover.py +753 -0
- package/pennyfarthing_scripts/cli.py +184 -0
- package/pennyfarthing_scripts/common/__init__.py +49 -0
- package/pennyfarthing_scripts/common/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/common/__pycache__/config.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/common/__pycache__/output.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/common/__pycache__/themes.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/common/config.py +91 -0
- package/pennyfarthing_scripts/common/output.py +180 -0
- package/pennyfarthing_scripts/common/themes.py +253 -0
- package/pennyfarthing_scripts/config.py +21 -0
- package/pennyfarthing_scripts/context.py +414 -0
- package/pennyfarthing_scripts/git/__init__.py +29 -0
- package/pennyfarthing_scripts/git/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/git/__pycache__/create_branches.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/git/__pycache__/status_all.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/git/create_branches.py +439 -0
- package/pennyfarthing_scripts/git/status_all.py +310 -0
- package/pennyfarthing_scripts/hooks/cyclist-pretooluse-hook.sh +7 -0
- package/pennyfarthing_scripts/hooks.py +454 -0
- package/pennyfarthing_scripts/hotspots/__init__.py +31 -0
- package/pennyfarthing_scripts/hotspots/__main__.py +6 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/analyze.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/formatters.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/__pycache__/models.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/hotspots/analyze.py +472 -0
- package/pennyfarthing_scripts/hotspots/cli.py +152 -0
- package/pennyfarthing_scripts/hotspots/formatters.py +109 -0
- package/pennyfarthing_scripts/hotspots/models.py +60 -0
- package/pennyfarthing_scripts/jira/__init__.py +99 -0
- package/pennyfarthing_scripts/jira/__main__.py +10 -0
- package/pennyfarthing_scripts/jira/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/bidirectional.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/claim.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/client.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/compat.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/create.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/epic.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/mappings.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/models.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/operations.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/reconcile.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/story.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/__pycache__/sync.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/jira/bidirectional.py +561 -0
- package/pennyfarthing_scripts/jira/claim.py +211 -0
- package/pennyfarthing_scripts/jira/cli.py +277 -0
- package/pennyfarthing_scripts/jira/client.py +762 -0
- package/pennyfarthing_scripts/jira/create.py +267 -0
- package/pennyfarthing_scripts/jira/epic.py +176 -0
- package/pennyfarthing_scripts/jira/operations.py +124 -0
- package/pennyfarthing_scripts/jira/reconcile.py +277 -0
- package/pennyfarthing_scripts/jira/story.py +219 -0
- package/pennyfarthing_scripts/jira/sync.py +350 -0
- package/pennyfarthing_scripts/jira_bidirectional_sync.py +37 -0
- package/pennyfarthing_scripts/jira_epic_creation.py +30 -0
- package/pennyfarthing_scripts/jira_sync.py +36 -0
- package/pennyfarthing_scripts/jira_sync_story.py +30 -0
- package/pennyfarthing_scripts/migration/__init__.py +39 -0
- package/pennyfarthing_scripts/migration/__main__.py +10 -0
- package/pennyfarthing_scripts/migration/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/session.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/skill.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/step.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/__pycache__/validate.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/migration/cli.py +304 -0
- package/pennyfarthing_scripts/migration/session.py +384 -0
- package/pennyfarthing_scripts/migration/skill.py +188 -0
- package/pennyfarthing_scripts/migration/step.py +229 -0
- package/pennyfarthing_scripts/migration/validate.py +282 -0
- package/pennyfarthing_scripts/output.py +37 -0
- package/pennyfarthing_scripts/patch_mode.py +449 -0
- package/pennyfarthing_scripts/preflight/__init__.py +17 -0
- package/pennyfarthing_scripts/preflight/__main__.py +10 -0
- package/pennyfarthing_scripts/preflight/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/preflight/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/preflight/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/preflight/__pycache__/finish.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/preflight/cli.py +141 -0
- package/pennyfarthing_scripts/preflight/finish.py +382 -0
- package/pennyfarthing_scripts/pretooluse_hook.py +193 -0
- package/pennyfarthing_scripts/prime/__init__.py +125 -0
- package/pennyfarthing_scripts/prime/__main__.py +8 -0
- package/pennyfarthing_scripts/prime/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/loader.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/models.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/persona.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/session.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/tiers.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/__pycache__/workflow.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/prime/cli.py +645 -0
- package/pennyfarthing_scripts/prime/loader.py +239 -0
- package/pennyfarthing_scripts/prime/models.py +206 -0
- package/pennyfarthing_scripts/prime/persona.py +309 -0
- package/pennyfarthing_scripts/prime/session.py +183 -0
- package/pennyfarthing_scripts/prime/tiers.py +201 -0
- package/pennyfarthing_scripts/prime/workflow.py +275 -0
- package/pennyfarthing_scripts/schema_validation_hook.py +306 -0
- package/pennyfarthing_scripts/sprint/__init__.py +66 -0
- package/pennyfarthing_scripts/sprint/__main__.py +10 -0
- package/pennyfarthing_scripts/sprint/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/archive.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/archive_epic.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/loader.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/status.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/story_add.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/story_update.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/validate_cmd.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/validator.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/work.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/__pycache__/yaml_io.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/sprint/archive.py +108 -0
- package/pennyfarthing_scripts/sprint/archive_epic.py +399 -0
- package/pennyfarthing_scripts/sprint/cli.py +373 -0
- package/pennyfarthing_scripts/sprint/import_epic.py +431 -0
- package/pennyfarthing_scripts/sprint/loader.py +193 -0
- package/pennyfarthing_scripts/sprint/status.py +122 -0
- package/pennyfarthing_scripts/sprint/story_add.py +187 -0
- package/pennyfarthing_scripts/sprint/story_update.py +181 -0
- package/pennyfarthing_scripts/sprint/validate_cmd.py +268 -0
- package/pennyfarthing_scripts/sprint/validator.py +570 -0
- package/pennyfarthing_scripts/sprint/work.py +192 -0
- package/pennyfarthing_scripts/sprint/yaml_io.py +258 -0
- package/pennyfarthing_scripts/story/__init__.py +67 -0
- package/pennyfarthing_scripts/story/__main__.py +10 -0
- package/pennyfarthing_scripts/story/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/__pycache__/__main__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/__pycache__/cli.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/__pycache__/create.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/__pycache__/size.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/__pycache__/template.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/story/cli.py +105 -0
- package/pennyfarthing_scripts/story/create.py +167 -0
- package/pennyfarthing_scripts/story/size.py +113 -0
- package/pennyfarthing_scripts/story/template.py +151 -0
- package/pennyfarthing_scripts/swebench.py +216 -0
- package/pennyfarthing_scripts/tests/__init__.py +1 -0
- package/pennyfarthing_scripts/tests/__pycache__/__init__.cpython-314.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/conftest.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_brownfield.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_cli_modules.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_common.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_git_utils.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_jira_package.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_package_structure.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_patch_mode.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_prime.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_sprint_package.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_sprint_validator.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_story_add.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_story_package.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_story_update.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_tiers.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_token_counting.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_validate_cmd.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_workflow_check.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_workflow_cli.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/__pycache__/test_yaml_io.cpython-314-pytest-9.0.2.pyc +0 -0
- package/pennyfarthing_scripts/tests/conftest.py +106 -0
- package/pennyfarthing_scripts/tests/test_brownfield.py +842 -0
- package/pennyfarthing_scripts/tests/test_cli_modules.py +245 -0
- package/pennyfarthing_scripts/tests/test_common.py +180 -0
- package/pennyfarthing_scripts/tests/test_git_utils.py +866 -0
- package/pennyfarthing_scripts/tests/test_jira_package.py +334 -0
- package/pennyfarthing_scripts/tests/test_package_structure.py +372 -0
- package/pennyfarthing_scripts/tests/test_patch_mode.py +830 -0
- package/pennyfarthing_scripts/tests/test_prime.py +1050 -0
- package/pennyfarthing_scripts/tests/test_sprint_package.py +236 -0
- package/pennyfarthing_scripts/tests/test_sprint_validator.py +731 -0
- package/pennyfarthing_scripts/tests/test_story_add.py +921 -0
- package/pennyfarthing_scripts/tests/test_story_package.py +156 -0
- package/pennyfarthing_scripts/tests/test_story_update.py +769 -0
- package/pennyfarthing_scripts/tests/test_tiers.py +1090 -0
- package/pennyfarthing_scripts/tests/test_token_counting.py +559 -0
- package/pennyfarthing_scripts/tests/test_validate_cmd.py +500 -0
- package/pennyfarthing_scripts/tests/test_workflow_check.py +341 -0
- package/pennyfarthing_scripts/tests/test_yaml_io.py +698 -0
- package/pennyfarthing_scripts/welcome_hook.py +157 -0
- package/pennyfarthing_scripts/workflow.py +287 -0
- package/dist/cli/commands/doctor.js.map +0 -1
- package/dist/cli/utils/settings.js.map +0 -1
- package/dist/cli/utils/themes.d.ts.map +0 -1
- package/pennyfarthing-dist/scripts/jira/jira-lib.sh +0 -464
- package/pennyfarthing-dist/scripts/jira/jira-sync.sh +0 -16
- package/pennyfarthing-dist/scripts/jira/sync-epic-to-jira.sh +0 -16
- /package/{bin → packages/core/bin}/pennyfarthing.js +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.js +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.test.js +0 -0
- /package/{dist → packages/core/dist}/bmad/context-reader.test.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.js +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.test.js +0 -0
- /package/{dist → packages/core/dist}/bmad/epics-parser.test.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/index.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/index.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/index.js +0 -0
- /package/{dist → packages/core/dist}/bmad/index.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.js +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.test.js +0 -0
- /package/{dist → packages/core/dist}/bmad/status-sync.test.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.js +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.test.js +0 -0
- /package/{dist → packages/core/dist}/bmad/story-exporter.test.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.js +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.js.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.test.js +0 -0
- /package/{dist → packages/core/dist}/bmad/story-parser.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/command.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/command.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/command.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/command.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/cyclist.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/doctor-legacy.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/doctor-legacy.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/doctor-legacy.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/doctor-legacy.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/e2e-fresh-install.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/e2e-fresh-install.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/e2e-upgrade.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/e2e-upgrade.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init-consolidation.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init-consolidation.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init-consolidation.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init-consolidation.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/init.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/persona-config-consolidation.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/persona-config-consolidation.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/persona-config-consolidation.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/persona-config-consolidation.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/skill.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/skill.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/skill.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/skill.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/theme.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/theme.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/theme.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/theme.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/uninstall.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/uninstall.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/uninstall.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/uninstall.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/update-consolidation.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/update-consolidation.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/update-consolidation.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/update-consolidation.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/update.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/version.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/commands/version.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/commands/version.js +0 -0
- /package/{dist → packages/core/dist}/cli/commands/version.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/customization.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/customization.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/customization.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/customization.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/cyclist-migration.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/cyclist-migration.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/cyclist-migration.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/cyclist-migration.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/index.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/index.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/index.js +0 -0
- /package/{dist → packages/core/dist}/cli/index.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/ocean-profiles.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/ocean-profiles.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/ocean-profiles.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/ocean-profiles.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/theme-maker.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/theme-maker.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/theme-maker.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/theme-maker.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/constants.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/constants.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/constants.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/constants.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/files.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/files.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/files.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/files.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/logger.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/logger.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/logger.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/logger.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/manifest.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/manifest.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/manifest.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/manifest.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/node-modules.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/node-modules.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/node-modules.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/node-modules.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/prompts.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/prompts.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/prompts.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/prompts.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/settings-consolidation.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/settings-consolidation.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/settings-consolidation.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/settings-consolidation.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/settings.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/symlinks.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/symlinks.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/symlinks.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/symlinks.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/themes.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/themes.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/themes.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/themes.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/themes.test.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/version.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/utils/version.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/utils/version.js +0 -0
- /package/{dist → packages/core/dist}/cli/utils/version.js.map +0 -0
- /package/{dist → packages/core/dist}/cli/workspace.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/cli/workspace.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/cli/workspace.test.js +0 -0
- /package/{dist → packages/core/dist}/cli/workspace.test.js.map +0 -0
- /package/{dist → packages/core/dist}/index.d.ts +0 -0
- /package/{dist → packages/core/dist}/index.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/index.js +0 -0
- /package/{dist → packages/core/dist}/index.js.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.d.ts +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.js +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.js.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.test.js +0 -0
- /package/{dist → packages/core/dist}/jira/jira-epic-creation.test.js.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.d.ts +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.js +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.js.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.test.js +0 -0
- /package/{dist → packages/core/dist}/jira/jira-sprint-sync.test.js.map +0 -0
- /package/{dist → packages/core/dist}/permissions/index.d.ts +0 -0
- /package/{dist → packages/core/dist}/permissions/index.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/permissions/index.js +0 -0
- /package/{dist → packages/core/dist}/permissions/index.js.map +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.d.ts +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.js +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.js.map +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.test.js +0 -0
- /package/{dist → packages/core/dist}/permissions/permission-schema.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/add-ocean-profiles.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/add-ocean-profiles.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/add-ocean-profiles.js +0 -0
- /package/{dist → packages/core/dist}/scripts/add-ocean-profiles.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.js +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/benchmark-integration.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/debugging-scenarios.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/debugging-scenarios.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/debugging-scenarios.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/debugging-scenarios.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-all-spiders.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-all-spiders.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-all-spiders.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-all-spiders.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-report.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider-report.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/generate-spider.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.js +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/job-fair-aggregator.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/run-ci.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/run-ci.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/run-ci.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/run-ci.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/theme-detail.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/theme-detail.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/theme-detail.test.js +0 -0
- /package/{dist → packages/core/dist}/scripts/theme-detail.test.js.map +0 -0
- /package/{dist → packages/core/dist}/scripts/validate-ocean-profiles.d.ts +0 -0
- /package/{dist → packages/core/dist}/scripts/validate-ocean-profiles.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/scripts/validate-ocean-profiles.js +0 -0
- /package/{dist → packages/core/dist}/scripts/validate-ocean-profiles.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/complete-step-integration.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/complete-step-integration.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/complete-step-integration.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/complete-step-integration.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.js +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/gate-handler.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-finish.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-finish.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-finish.js +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-finish.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-setup.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-setup.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-setup.js +0 -0
- /package/{dist → packages/core/dist}/workflow/generic-sm-setup.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.js +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/handoff.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/index.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/index.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/index.js +0 -0
- /package/{dist → packages/core/dist}/workflow/index.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.js +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/session-state.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/sm-subagents.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/sm-subagents.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/sm-subagents.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/sm-subagents.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.js +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/step-parser.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/story-workflow-routing.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/story-workflow-routing.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/story-workflow-routing.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/story-workflow-routing.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.js +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/test-cache.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.js +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/trimodal.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.js +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/variable-resolver.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-executor.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-loader.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-migration.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-migration.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-migration.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-migration.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-permissions.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-router.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-schema.test.js.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-stepped-schema.test.d.ts +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-stepped-schema.test.d.ts.map +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-stepped-schema.test.js +0 -0
- /package/{dist → packages/core/dist}/workflow/workflow-stepped-schema.test.js.map +0 -0
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Import BMAD epics-and-stories output to future.yaml.
|
|
3
|
+
|
|
4
|
+
Transforms the markdown output from the epics-and-stories workflow into
|
|
5
|
+
the YAML format used by sprint/future.yaml.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
import re
|
|
9
|
+
from datetime import date
|
|
10
|
+
from pathlib import Path
|
|
11
|
+
from typing import Any
|
|
12
|
+
|
|
13
|
+
import yaml
|
|
14
|
+
|
|
15
|
+
from pennyfarthing_scripts.common.config import get_project_root, load_yaml_config
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
def parse_epics_markdown(content: str) -> dict[str, Any]:
|
|
19
|
+
"""Parse epics markdown file from BMAD epics-and-stories workflow.
|
|
20
|
+
|
|
21
|
+
Args:
|
|
22
|
+
content: Markdown content to parse
|
|
23
|
+
|
|
24
|
+
Returns:
|
|
25
|
+
Dict with parsed initiative data
|
|
26
|
+
"""
|
|
27
|
+
result: dict[str, Any] = {
|
|
28
|
+
"title": "",
|
|
29
|
+
"description": "",
|
|
30
|
+
"total_points": 0,
|
|
31
|
+
"epics": [],
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
# Extract title from first # heading
|
|
35
|
+
title_match = re.search(r"^# (.+?)( - Epic Breakdown)?$", content, re.MULTILINE)
|
|
36
|
+
if title_match:
|
|
37
|
+
result["title"] = title_match.group(1).replace(" - Epics and Stories", "")
|
|
38
|
+
|
|
39
|
+
# Extract description from Overview section
|
|
40
|
+
overview_match = re.search(
|
|
41
|
+
r"## Overview\s*\n\s*\n(.+?)(?=\n\n##|\n##)", content, re.DOTALL
|
|
42
|
+
)
|
|
43
|
+
if overview_match:
|
|
44
|
+
result["description"] = overview_match.group(1).strip()
|
|
45
|
+
|
|
46
|
+
# Extract total points
|
|
47
|
+
points_match = re.search(r"\*\*Points:\*\*\s*(\d+)", content)
|
|
48
|
+
if points_match:
|
|
49
|
+
result["total_points"] = int(points_match.group(1))
|
|
50
|
+
else:
|
|
51
|
+
effort_match = re.search(
|
|
52
|
+
r"Total Effort.*?(\d+)\s*story points", content, re.IGNORECASE
|
|
53
|
+
)
|
|
54
|
+
if effort_match:
|
|
55
|
+
result["total_points"] = int(effort_match.group(1))
|
|
56
|
+
|
|
57
|
+
# Parse all epics
|
|
58
|
+
epic_pattern = re.compile(r"^## Epic (\d+):\s*(.+)$", re.MULTILINE)
|
|
59
|
+
epic_positions = []
|
|
60
|
+
for match in epic_pattern.finditer(content):
|
|
61
|
+
epic_positions.append(
|
|
62
|
+
{
|
|
63
|
+
"num": int(match.group(1)),
|
|
64
|
+
"title": match.group(2),
|
|
65
|
+
"index": match.start(),
|
|
66
|
+
}
|
|
67
|
+
)
|
|
68
|
+
|
|
69
|
+
# Process each epic
|
|
70
|
+
for i, epic_pos in enumerate(epic_positions):
|
|
71
|
+
start_index = epic_pos["index"]
|
|
72
|
+
end_index = (
|
|
73
|
+
epic_positions[i + 1]["index"] if i < len(epic_positions) - 1 else len(content)
|
|
74
|
+
)
|
|
75
|
+
epic_content = content[start_index:end_index]
|
|
76
|
+
|
|
77
|
+
epic: dict[str, Any] = {
|
|
78
|
+
"num": epic_pos["num"],
|
|
79
|
+
"title": epic_pos["title"],
|
|
80
|
+
"description": "",
|
|
81
|
+
"points": 0,
|
|
82
|
+
"stories": [],
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
# Extract epic description (User Outcome)
|
|
86
|
+
user_outcome_match = re.search(r"\*\*User Outcome:\*\*\s*(.+)", epic_content)
|
|
87
|
+
if user_outcome_match:
|
|
88
|
+
epic["description"] = user_outcome_match.group(1)
|
|
89
|
+
|
|
90
|
+
# Extract epic points
|
|
91
|
+
epic_points_match = re.search(r"\*\*Points:\*\*\s*(\d+)", epic_content)
|
|
92
|
+
if epic_points_match:
|
|
93
|
+
epic["points"] = int(epic_points_match.group(1))
|
|
94
|
+
|
|
95
|
+
# Parse stories within this epic
|
|
96
|
+
story_pattern = re.compile(
|
|
97
|
+
rf"^### Story {epic_pos['num']}\.(\d+):\s*(.+)$", re.MULTILINE
|
|
98
|
+
)
|
|
99
|
+
story_positions = []
|
|
100
|
+
for match in story_pattern.finditer(epic_content):
|
|
101
|
+
story_positions.append(
|
|
102
|
+
{
|
|
103
|
+
"num": int(match.group(1)),
|
|
104
|
+
"title": match.group(2),
|
|
105
|
+
"index": match.start(),
|
|
106
|
+
}
|
|
107
|
+
)
|
|
108
|
+
|
|
109
|
+
for j, story_pos in enumerate(story_positions):
|
|
110
|
+
story_start = story_pos["index"]
|
|
111
|
+
story_end = (
|
|
112
|
+
story_positions[j + 1]["index"]
|
|
113
|
+
if j < len(story_positions) - 1
|
|
114
|
+
else len(epic_content)
|
|
115
|
+
)
|
|
116
|
+
story_content = epic_content[story_start:story_end]
|
|
117
|
+
|
|
118
|
+
# Extract story description
|
|
119
|
+
i_want_match = re.search(r"^I want \*\*(.+?)\*\*,", story_content, re.MULTILINE)
|
|
120
|
+
description = i_want_match.group(1) if i_want_match else ""
|
|
121
|
+
|
|
122
|
+
# Extract story points
|
|
123
|
+
story_points_match = re.search(r"\*\*Points:\*\*\s*(\d+)", story_content)
|
|
124
|
+
points = int(story_points_match.group(1)) if story_points_match else 1
|
|
125
|
+
|
|
126
|
+
epic["stories"].append(
|
|
127
|
+
{
|
|
128
|
+
"num": story_pos["num"],
|
|
129
|
+
"title": story_pos["title"],
|
|
130
|
+
"description": description,
|
|
131
|
+
"points": points,
|
|
132
|
+
}
|
|
133
|
+
)
|
|
134
|
+
|
|
135
|
+
result["epics"].append(epic)
|
|
136
|
+
|
|
137
|
+
# Calculate total if not found
|
|
138
|
+
if result["total_points"] == 0:
|
|
139
|
+
result["total_points"] = sum(e.get("points", 0) for e in result["epics"])
|
|
140
|
+
|
|
141
|
+
return result
|
|
142
|
+
|
|
143
|
+
|
|
144
|
+
def get_next_epic_number(project_root: Path | None = None) -> int:
|
|
145
|
+
"""Get next available epic number from future.yaml.
|
|
146
|
+
|
|
147
|
+
Args:
|
|
148
|
+
project_root: Project root path (defaults to auto-detect)
|
|
149
|
+
|
|
150
|
+
Returns:
|
|
151
|
+
Next available epic number
|
|
152
|
+
"""
|
|
153
|
+
root = project_root or get_project_root()
|
|
154
|
+
future_path = root / "sprint" / "future.yaml"
|
|
155
|
+
|
|
156
|
+
if not future_path.exists():
|
|
157
|
+
return 74 # Default starting point
|
|
158
|
+
|
|
159
|
+
content = future_path.read_text()
|
|
160
|
+
|
|
161
|
+
# Look for "Next Available Epic Number: XX"
|
|
162
|
+
next_match = re.search(r"Next Available Epic Number:\s*(\d+)", content, re.IGNORECASE)
|
|
163
|
+
if next_match:
|
|
164
|
+
return int(next_match.group(1))
|
|
165
|
+
|
|
166
|
+
# Fallback: find highest epic-XX number
|
|
167
|
+
max_num = 73
|
|
168
|
+
for match in re.finditer(r"epic-(\d+)", content):
|
|
169
|
+
num = int(match.group(1))
|
|
170
|
+
if num > max_num:
|
|
171
|
+
max_num = num
|
|
172
|
+
|
|
173
|
+
return max_num + 1
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
def generate_initiative_yaml(
|
|
177
|
+
parsed: dict[str, Any],
|
|
178
|
+
start_epic_num: int,
|
|
179
|
+
initiative_name: str,
|
|
180
|
+
source_file: str,
|
|
181
|
+
marker: str = "imported",
|
|
182
|
+
) -> tuple[str, int]:
|
|
183
|
+
"""Generate YAML for an initiative.
|
|
184
|
+
|
|
185
|
+
Args:
|
|
186
|
+
parsed: Parsed markdown data
|
|
187
|
+
start_epic_num: Starting epic number
|
|
188
|
+
initiative_name: Name for the initiative
|
|
189
|
+
source_file: Path to source markdown file
|
|
190
|
+
marker: Marker tag for stories
|
|
191
|
+
|
|
192
|
+
Returns:
|
|
193
|
+
Tuple of (YAML string, next epic number)
|
|
194
|
+
"""
|
|
195
|
+
today = date.today().isoformat()
|
|
196
|
+
|
|
197
|
+
lines = [
|
|
198
|
+
f" # ==========================================================================",
|
|
199
|
+
f" # {initiative_name.upper()}",
|
|
200
|
+
f" # Imported from: {source_file}",
|
|
201
|
+
f" # Date: {today}",
|
|
202
|
+
f" # ==========================================================================",
|
|
203
|
+
f' - name: "{initiative_name}"',
|
|
204
|
+
f" description: |",
|
|
205
|
+
]
|
|
206
|
+
|
|
207
|
+
# Add description lines with proper indentation
|
|
208
|
+
for line in parsed.get("description", initiative_name).split("\n"):
|
|
209
|
+
lines.append(f" {line}")
|
|
210
|
+
|
|
211
|
+
lines.extend(
|
|
212
|
+
[
|
|
213
|
+
f" status: ready",
|
|
214
|
+
f" blocked_by: null",
|
|
215
|
+
f" total_points: {parsed['total_points']}",
|
|
216
|
+
f" epics:",
|
|
217
|
+
]
|
|
218
|
+
)
|
|
219
|
+
|
|
220
|
+
current_epic_num = start_epic_num
|
|
221
|
+
|
|
222
|
+
for epic in parsed.get("epics", []):
|
|
223
|
+
epic_points = epic.get("points", 0)
|
|
224
|
+
if epic_points == 0:
|
|
225
|
+
epic_points = sum(s.get("points", 1) for s in epic.get("stories", []))
|
|
226
|
+
|
|
227
|
+
lines.extend(
|
|
228
|
+
[
|
|
229
|
+
f" - id: epic-{current_epic_num}",
|
|
230
|
+
f' title: "{epic["title"]}"',
|
|
231
|
+
f" description: |",
|
|
232
|
+
f" {epic.get('description', epic['title'])}",
|
|
233
|
+
f" points: {epic_points}",
|
|
234
|
+
f" priority: P1",
|
|
235
|
+
f' marker: "{marker}"',
|
|
236
|
+
f" repos: pennyfarthing",
|
|
237
|
+
f" status: planning",
|
|
238
|
+
f" stories:",
|
|
239
|
+
]
|
|
240
|
+
)
|
|
241
|
+
|
|
242
|
+
for story in epic.get("stories", []):
|
|
243
|
+
story_id = f"{current_epic_num}-{story['num']}"
|
|
244
|
+
# Escape quotes in title
|
|
245
|
+
title = story["title"].replace('"', '\\"')
|
|
246
|
+
lines.extend(
|
|
247
|
+
[
|
|
248
|
+
f' - id: "{story_id}"',
|
|
249
|
+
f' title: "{title}"',
|
|
250
|
+
f" description: |",
|
|
251
|
+
f" {story.get('description', title)}",
|
|
252
|
+
f" points: {story.get('points', 1)}",
|
|
253
|
+
f" priority: P0",
|
|
254
|
+
f" status: planning",
|
|
255
|
+
f" repos: pennyfarthing",
|
|
256
|
+
]
|
|
257
|
+
)
|
|
258
|
+
|
|
259
|
+
current_epic_num += 1
|
|
260
|
+
|
|
261
|
+
return "\n".join(lines), current_epic_num
|
|
262
|
+
|
|
263
|
+
|
|
264
|
+
def import_epic(
|
|
265
|
+
epics_file: str | Path,
|
|
266
|
+
initiative_name: str | None = None,
|
|
267
|
+
marker: str = "imported",
|
|
268
|
+
*,
|
|
269
|
+
project_root: Path | None = None,
|
|
270
|
+
dry_run: bool = False,
|
|
271
|
+
) -> dict[str, Any]:
|
|
272
|
+
"""Import BMAD epics-and-stories markdown to future.yaml.
|
|
273
|
+
|
|
274
|
+
Args:
|
|
275
|
+
epics_file: Path to the markdown file from epics-and-stories workflow
|
|
276
|
+
initiative_name: Name for the initiative (extracted from file if not provided)
|
|
277
|
+
marker: Marker tag for stories
|
|
278
|
+
project_root: Project root path (defaults to auto-detect)
|
|
279
|
+
dry_run: If True, show what would be done without making changes
|
|
280
|
+
|
|
281
|
+
Returns:
|
|
282
|
+
Dict with success status and details
|
|
283
|
+
"""
|
|
284
|
+
root = project_root or get_project_root()
|
|
285
|
+
|
|
286
|
+
# Resolve epics file path
|
|
287
|
+
epics_path = Path(epics_file)
|
|
288
|
+
if not epics_path.is_absolute():
|
|
289
|
+
epics_path = root / epics_path
|
|
290
|
+
|
|
291
|
+
if not epics_path.exists():
|
|
292
|
+
return {"success": False, "error": f"File not found: {epics_path}"}
|
|
293
|
+
|
|
294
|
+
# Read and parse
|
|
295
|
+
content = epics_path.read_text()
|
|
296
|
+
parsed = parse_epics_markdown(content)
|
|
297
|
+
|
|
298
|
+
if not parsed.get("epics"):
|
|
299
|
+
return {"success": False, "error": "No epics found in markdown file"}
|
|
300
|
+
|
|
301
|
+
# Use provided name or extract from file
|
|
302
|
+
name = initiative_name or parsed.get("title") or "Imported Initiative"
|
|
303
|
+
|
|
304
|
+
# Get next epic number
|
|
305
|
+
start_epic_num = get_next_epic_number(root)
|
|
306
|
+
|
|
307
|
+
# Generate YAML
|
|
308
|
+
relative_path = str(epics_path.relative_to(root)) if epics_path.is_relative_to(root) else str(epics_path)
|
|
309
|
+
new_yaml, next_epic_num = generate_initiative_yaml(
|
|
310
|
+
parsed, start_epic_num, name, relative_path, marker
|
|
311
|
+
)
|
|
312
|
+
|
|
313
|
+
if dry_run:
|
|
314
|
+
return {
|
|
315
|
+
"success": True,
|
|
316
|
+
"dry_run": True,
|
|
317
|
+
"initiative_name": name,
|
|
318
|
+
"epics_count": len(parsed["epics"]),
|
|
319
|
+
"stories_count": sum(len(e.get("stories", [])) for e in parsed["epics"]),
|
|
320
|
+
"total_points": parsed["total_points"],
|
|
321
|
+
"start_epic_num": start_epic_num,
|
|
322
|
+
"next_epic_num": next_epic_num,
|
|
323
|
+
"yaml_preview": new_yaml,
|
|
324
|
+
"message": f"Would import '{name}' with {len(parsed['epics'])} epics",
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
# Update future.yaml
|
|
328
|
+
future_path = root / "sprint" / "future.yaml"
|
|
329
|
+
future_content = future_path.read_text()
|
|
330
|
+
|
|
331
|
+
# Update next epic number comment
|
|
332
|
+
future_content = re.sub(
|
|
333
|
+
r"Next Available Epic Number:\s*\d+",
|
|
334
|
+
f"Next Available Epic Number: {next_epic_num}",
|
|
335
|
+
future_content,
|
|
336
|
+
flags=re.IGNORECASE,
|
|
337
|
+
)
|
|
338
|
+
|
|
339
|
+
# Find insertion point (before SUMMARY section)
|
|
340
|
+
summary_marker = "# =============================================================================\n# SUMMARY"
|
|
341
|
+
summary_index = future_content.find(summary_marker)
|
|
342
|
+
|
|
343
|
+
if summary_index == -1:
|
|
344
|
+
future_content += "\n" + new_yaml
|
|
345
|
+
else:
|
|
346
|
+
future_content = (
|
|
347
|
+
future_content[:summary_index] + new_yaml + "\n" + future_content[summary_index:]
|
|
348
|
+
)
|
|
349
|
+
|
|
350
|
+
future_path.write_text(future_content)
|
|
351
|
+
|
|
352
|
+
return {
|
|
353
|
+
"success": True,
|
|
354
|
+
"initiative_name": name,
|
|
355
|
+
"epics_count": len(parsed["epics"]),
|
|
356
|
+
"stories_count": sum(len(e.get("stories", [])) for e in parsed["epics"]),
|
|
357
|
+
"total_points": parsed["total_points"],
|
|
358
|
+
"start_epic_num": start_epic_num,
|
|
359
|
+
"next_epic_num": next_epic_num,
|
|
360
|
+
"message": f"Imported '{name}' with {len(parsed['epics'])} epics (epic-{start_epic_num} to epic-{next_epic_num - 1})",
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
|
|
364
|
+
def main(args: list[str] | None = None) -> int:
|
|
365
|
+
"""CLI entry point for epic import.
|
|
366
|
+
|
|
367
|
+
Args:
|
|
368
|
+
args: Command line arguments
|
|
369
|
+
|
|
370
|
+
Returns:
|
|
371
|
+
Exit code
|
|
372
|
+
"""
|
|
373
|
+
import argparse
|
|
374
|
+
import sys
|
|
375
|
+
|
|
376
|
+
parser = argparse.ArgumentParser(
|
|
377
|
+
description="Import BMAD epics-and-stories workflow output to future.yaml"
|
|
378
|
+
)
|
|
379
|
+
parser.add_argument(
|
|
380
|
+
"epics_file",
|
|
381
|
+
help="Path to the markdown file from epics-and-stories workflow",
|
|
382
|
+
)
|
|
383
|
+
parser.add_argument(
|
|
384
|
+
"initiative_name",
|
|
385
|
+
nargs="?",
|
|
386
|
+
help="Name for the initiative (optional, extracted from file if not provided)",
|
|
387
|
+
)
|
|
388
|
+
parser.add_argument(
|
|
389
|
+
"--marker",
|
|
390
|
+
default="imported",
|
|
391
|
+
help="Marker tag for stories (default: imported)",
|
|
392
|
+
)
|
|
393
|
+
parser.add_argument(
|
|
394
|
+
"--dry-run",
|
|
395
|
+
action="store_true",
|
|
396
|
+
help="Show what would be done without making changes",
|
|
397
|
+
)
|
|
398
|
+
|
|
399
|
+
parsed = parser.parse_args(args)
|
|
400
|
+
|
|
401
|
+
result = import_epic(
|
|
402
|
+
parsed.epics_file,
|
|
403
|
+
initiative_name=parsed.initiative_name,
|
|
404
|
+
marker=parsed.marker,
|
|
405
|
+
dry_run=parsed.dry_run,
|
|
406
|
+
)
|
|
407
|
+
|
|
408
|
+
if result.get("success"):
|
|
409
|
+
if result.get("dry_run"):
|
|
410
|
+
print(f"[DRY-RUN] {result.get('message')}")
|
|
411
|
+
print(f" Epics: {result.get('epics_count')}")
|
|
412
|
+
print(f" Stories: {result.get('stories_count')}")
|
|
413
|
+
print(f" Points: {result.get('total_points')}")
|
|
414
|
+
print(f" Epic numbers: epic-{result.get('start_epic_num')} to epic-{result.get('next_epic_num') - 1}")
|
|
415
|
+
print("\nYAML Preview:")
|
|
416
|
+
print("-" * 60)
|
|
417
|
+
print(result.get("yaml_preview"))
|
|
418
|
+
print("-" * 60)
|
|
419
|
+
else:
|
|
420
|
+
print(f"✓ {result.get('message')}")
|
|
421
|
+
print(f" Next available epic number: {result.get('next_epic_num')}")
|
|
422
|
+
return 0
|
|
423
|
+
else:
|
|
424
|
+
print(f"Failed: {result.get('error')}", file=sys.stderr)
|
|
425
|
+
return 1
|
|
426
|
+
|
|
427
|
+
|
|
428
|
+
if __name__ == "__main__":
|
|
429
|
+
import sys
|
|
430
|
+
|
|
431
|
+
sys.exit(main())
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Sprint YAML parsing utilities for Pennyfarthing scripts.
|
|
3
|
+
|
|
4
|
+
Provides access to sprint/current-sprint.yaml data.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from pathlib import Path
|
|
8
|
+
from typing import Any
|
|
9
|
+
|
|
10
|
+
from pennyfarthing_scripts.common.config import get_project_root, load_yaml_config
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
def load_sprint(project_root: Path | None = None) -> dict[str, Any] | None:
|
|
14
|
+
"""Load sprint data from project root.
|
|
15
|
+
|
|
16
|
+
Args:
|
|
17
|
+
project_root: Project root path (defaults to auto-detect)
|
|
18
|
+
|
|
19
|
+
Returns:
|
|
20
|
+
Sprint data as dict, or None if not found
|
|
21
|
+
"""
|
|
22
|
+
root = project_root or get_project_root()
|
|
23
|
+
sprint_path = root / "sprint" / "current-sprint.yaml"
|
|
24
|
+
return load_yaml_config(sprint_path)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def find_epic(sprint_data: dict[str, Any], epic_num: str) -> dict[str, Any] | None:
|
|
28
|
+
"""Find epic in sprint data (handles various ID formats).
|
|
29
|
+
|
|
30
|
+
Args:
|
|
31
|
+
sprint_data: Sprint YAML data
|
|
32
|
+
epic_num: Epic number (e.g., "63", "epic-63", or "63")
|
|
33
|
+
|
|
34
|
+
Returns:
|
|
35
|
+
Epic dict if found, None otherwise
|
|
36
|
+
"""
|
|
37
|
+
if not sprint_data or "epics" not in sprint_data:
|
|
38
|
+
return None
|
|
39
|
+
|
|
40
|
+
# Normalize the epic number
|
|
41
|
+
epic_num_clean = epic_num.replace("epic-", "")
|
|
42
|
+
|
|
43
|
+
for epic in sprint_data["epics"]:
|
|
44
|
+
epic_id = str(epic.get("id", ""))
|
|
45
|
+
# Match "63", "epic-63", or just the number
|
|
46
|
+
if epic_id == epic_num or epic_id == f"epic-{epic_num}" or epic_id == epic_num_clean:
|
|
47
|
+
return epic
|
|
48
|
+
# Also try without prefix
|
|
49
|
+
if epic_id.replace("epic-", "") == epic_num_clean:
|
|
50
|
+
return epic
|
|
51
|
+
|
|
52
|
+
return None
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
# Alias for backwards compatibility
|
|
56
|
+
load_current_sprint = load_sprint
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
def get_sprint_info() -> dict[str, Any]:
|
|
60
|
+
"""Get sprint metadata (number, dates, status, etc).
|
|
61
|
+
|
|
62
|
+
Returns:
|
|
63
|
+
Sprint info dict with number, status, goal, etc.
|
|
64
|
+
"""
|
|
65
|
+
data = load_sprint()
|
|
66
|
+
if data and "sprint" in data:
|
|
67
|
+
return data["sprint"]
|
|
68
|
+
return {}
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
def get_all_stories() -> list[dict[str, Any]]:
|
|
72
|
+
"""Get all stories from all epics.
|
|
73
|
+
|
|
74
|
+
Returns:
|
|
75
|
+
Flat list of all story dicts
|
|
76
|
+
"""
|
|
77
|
+
data = load_sprint()
|
|
78
|
+
if not data or "epics" not in data:
|
|
79
|
+
return []
|
|
80
|
+
|
|
81
|
+
stories = []
|
|
82
|
+
for epic in data["epics"]:
|
|
83
|
+
if "stories" in epic:
|
|
84
|
+
stories.extend(epic["stories"])
|
|
85
|
+
return stories
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def get_story_by_id(story_id: str) -> dict[str, Any] | None:
|
|
89
|
+
"""Find a story by its ID.
|
|
90
|
+
|
|
91
|
+
Args:
|
|
92
|
+
story_id: The story ID (e.g., "63-4" or "MSSCI-12398")
|
|
93
|
+
|
|
94
|
+
Returns:
|
|
95
|
+
Story dict if found, None otherwise
|
|
96
|
+
"""
|
|
97
|
+
for story in get_all_stories():
|
|
98
|
+
if story.get("id") == story_id:
|
|
99
|
+
return story
|
|
100
|
+
# Also check jira field
|
|
101
|
+
if story.get("jira") == story_id:
|
|
102
|
+
return story
|
|
103
|
+
return None
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
def get_stories_by_status(status: str) -> list[dict[str, Any]]:
|
|
107
|
+
"""Get all stories with a given status.
|
|
108
|
+
|
|
109
|
+
Args:
|
|
110
|
+
status: Status to filter by (e.g., "backlog", "in_progress", "done")
|
|
111
|
+
|
|
112
|
+
Returns:
|
|
113
|
+
List of stories matching the status
|
|
114
|
+
"""
|
|
115
|
+
return [s for s in get_all_stories() if s.get("status") == status]
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
def get_epic_by_id(epic_id: str) -> dict[str, Any] | None:
|
|
119
|
+
"""Find an epic by its ID.
|
|
120
|
+
|
|
121
|
+
Args:
|
|
122
|
+
epic_id: The epic ID
|
|
123
|
+
|
|
124
|
+
Returns:
|
|
125
|
+
Epic dict if found, None otherwise
|
|
126
|
+
"""
|
|
127
|
+
data = load_sprint()
|
|
128
|
+
if not data or "epics" not in data:
|
|
129
|
+
return None
|
|
130
|
+
|
|
131
|
+
for epic in data["epics"]:
|
|
132
|
+
if epic.get("id") == epic_id:
|
|
133
|
+
return epic
|
|
134
|
+
return None
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
def find_story(epic: dict[str, Any] | None, story_id: str) -> dict[str, Any] | None:
|
|
138
|
+
"""Find a story within an epic by its ID.
|
|
139
|
+
|
|
140
|
+
Args:
|
|
141
|
+
epic: Epic dict containing stories
|
|
142
|
+
story_id: The story ID (e.g., "63-7")
|
|
143
|
+
|
|
144
|
+
Returns:
|
|
145
|
+
Story dict if found, None otherwise
|
|
146
|
+
"""
|
|
147
|
+
if not epic or "stories" not in epic:
|
|
148
|
+
return None
|
|
149
|
+
|
|
150
|
+
for story in epic["stories"]:
|
|
151
|
+
if story.get("id") == story_id:
|
|
152
|
+
return story
|
|
153
|
+
|
|
154
|
+
return None
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
def get_story_field(
|
|
158
|
+
sprint_data: dict[str, Any], story_id: str, field_name: str
|
|
159
|
+
) -> Any | None:
|
|
160
|
+
"""Get a specific field from a story in sprint data.
|
|
161
|
+
|
|
162
|
+
Extracts the epic number from the story ID (e.g., "63-7" -> epic 63)
|
|
163
|
+
and looks up the story within that epic.
|
|
164
|
+
|
|
165
|
+
Args:
|
|
166
|
+
sprint_data: Sprint YAML data
|
|
167
|
+
story_id: The story ID (e.g., "63-7")
|
|
168
|
+
field_name: The field to extract (e.g., "status", "points", "workflow")
|
|
169
|
+
|
|
170
|
+
Returns:
|
|
171
|
+
Field value if found, None otherwise
|
|
172
|
+
"""
|
|
173
|
+
if not sprint_data or not story_id:
|
|
174
|
+
return None
|
|
175
|
+
|
|
176
|
+
# Extract epic number from story ID (e.g., "63-7" -> "63")
|
|
177
|
+
parts = story_id.split("-")
|
|
178
|
+
if len(parts) < 2:
|
|
179
|
+
return None
|
|
180
|
+
|
|
181
|
+
epic_num = parts[0]
|
|
182
|
+
|
|
183
|
+
# Find the epic
|
|
184
|
+
epic = find_epic(sprint_data, epic_num)
|
|
185
|
+
if not epic:
|
|
186
|
+
return None
|
|
187
|
+
|
|
188
|
+
# Find the story within the epic
|
|
189
|
+
story = find_story(epic, story_id)
|
|
190
|
+
if not story:
|
|
191
|
+
return None
|
|
192
|
+
|
|
193
|
+
return story.get(field_name)
|