Merge e7cc716e87 into 5579816ed2
This commit is contained in:
commit
827ddfca6b
|
|
@ -43,6 +43,7 @@
|
|||
"test": "npm run test:schemas && npm run test:refs && npm run test:install && npm run validate:schemas && npm run lint && npm run lint:md && npm run format:check",
|
||||
"test:coverage": "c8 --reporter=text --reporter=html npm run test:schemas",
|
||||
"test:install": "node test/test-installation-components.js",
|
||||
"test:monorepo": "node test/test-monorepo-validation.js",
|
||||
"test:refs": "node test/test-file-refs-csv.js",
|
||||
"test:schemas": "node test/test-agent-schema.js",
|
||||
"validate:refs": "node tools/validate-file-refs.js",
|
||||
|
|
|
|||
|
|
@ -28,4 +28,5 @@ bmm,4-implementation,Create Story,CS,30,_bmad/bmm/workflows/4-implementation/cre
|
|||
bmm,4-implementation,Dev Story,DS,40,_bmad/bmm/workflows/4-implementation/dev-story/workflow.yaml,bmad-bmm-dev-story,true,dev,Create Mode,"Story cycle: Execute story implementation tasks and tests then CR then back to DS if fixes needed",,,
|
||||
bmm,4-implementation,Code Review,CR,50,_bmad/bmm/workflows/4-implementation/code-review/workflow.yaml,bmad-bmm-code-review,false,dev,Create Mode,"Story cycle: If issues back to DS if approved then next CS or ER if epic complete",,,
|
||||
bmm,4-implementation,QA Automation Test,QA,45,_bmad/bmm/workflows/qa/automate/workflow.yaml,bmad-bmm-qa-automate,false,qa,Create Mode,"Generate automated API and E2E tests for implemented code using the project's existing test framework (detects existing well known in use test frameworks). Use after implementation to add test coverage. NOT for code review or story validation - use CR for that.",implementation_artifacts,"test suite",
|
||||
bmm,anytime,Set Project,SPJ,05,_bmad/bmm/workflows/0-context/set-project/workflow.md,bmad-set-project,false,bmad-master,Anytime,"Set or clear the current project context for monorepo support.",_bmad,.current_project,
|
||||
bmm,4-implementation,Retrospective,ER,60,_bmad/bmm/workflows/4-implementation/retrospective/workflow.yaml,bmad-bmm-retrospective,false,sm,Create Mode,"Optional at epic end: Review completed work lessons learned and next epic or if major issues consider CC",implementation_artifacts,retrospective,
|
||||
|
|
|
|||
|
|
|
@ -0,0 +1,36 @@
|
|||
---
|
||||
name: set-project
|
||||
description: Set the current project context for monorepo support
|
||||
main_config: '{project-root}/_bmad/bmm/config.yaml'
|
||||
---
|
||||
|
||||
# Set Project Context
|
||||
|
||||
**Goal:** Configure the active project path for BMAD artifacts.
|
||||
|
||||
**Your Role:** Configuration Assistant.
|
||||
|
||||
## WORKFLOW ARCHITECTURE
|
||||
|
||||
This is a single-step workflow that updates a local state file.
|
||||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
### 2. Context Management
|
||||
|
||||
1. **Ask User:** "Please enter the **project name** or path relative to `_bmad-output/` (e.g. `project-name` or `libs/auth-lib`). Enter `CLEAR` to reset to root."
|
||||
2. **Wait for Input.**
|
||||
3. **Process Input:**
|
||||
- **Case: CLEAR**:
|
||||
- Delete file: `{project-root}/_bmad/.current_project`
|
||||
- Output: "✅ Project context cleared. Artifacts will go to root `_bmad-output/`."
|
||||
- **Case: Path Provided**:
|
||||
- **Sanitize:** Remove leading `/` or `_bmad-output/` if present in the input.
|
||||
- Write file: `{project-root}/_bmad/.current_project` with content `<sanitized_path>`
|
||||
- Output: "✅ Project context set to: `<sanitized_path>`. Artifacts will go to `_bmad-output/<sanitized_path>/`."
|
||||
|
||||
### 3. Verification
|
||||
|
||||
- Display the full resolved output path for confirmation.
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
---
|
||||
name: create-product-brief
|
||||
description: Create comprehensive product briefs through collaborative step-by-step discovery as creative Business Analyst working with the user as peers.
|
||||
main_config: '{project-root}/_bmad/bmm/config.yaml'
|
||||
---
|
||||
|
||||
# Product Brief Workflow
|
||||
|
|
@ -48,7 +49,12 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {project-root}/_bmad/bmm/config.yaml and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`, `communication_language`, `document_output_language`, `user_skill_level`
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
---
|
||||
name: domain-research
|
||||
description: Conduct domain research covering industry analysis, regulations, technology trends, and ecosystem dynamics using current web data and verified sources.
|
||||
main_config: '{project-root}/_bmad/bmm/config.yaml'
|
||||
---
|
||||
|
||||
# Domain Research Workflow
|
||||
|
|
@ -15,7 +16,15 @@ description: Conduct domain research covering industry analysis, regulations, te
|
|||
|
||||
## CONFIGURATION
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
- `date` as a system-generated value
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
---
|
||||
name: market-research
|
||||
description: Conduct market research covering market size, growth, competition, and customer insights using current web data and verified sources.
|
||||
main_config: '{project-root}/_bmad/bmm/config.yaml'
|
||||
---
|
||||
|
||||
# Market Research Workflow
|
||||
|
|
@ -15,7 +16,15 @@ description: Conduct market research covering market size, growth, competition,
|
|||
|
||||
## CONFIGURATION
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
- `date` as a system-generated value
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
---
|
||||
name: technical-research
|
||||
description: Conduct technical research covering technology evaluation, architecture decisions, and implementation approaches using current web data and verified sources.
|
||||
main_config: '{project-root}/_bmad/bmm/config.yaml'
|
||||
---
|
||||
|
||||
# Technical Research Workflow
|
||||
|
|
@ -15,7 +16,15 @@ description: Conduct technical research covering technology evaluation, architec
|
|||
|
||||
## CONFIGURATION
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
- `date` as a system-generated value
|
||||
|
|
|
|||
|
|
@ -48,7 +48,12 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
|
|
|
|||
|
|
@ -48,8 +48,12 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
- `date` as system-generated current datetime
|
||||
|
|
|
|||
|
|
@ -48,7 +48,12 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
|
|
|
|||
|
|
@ -22,9 +22,14 @@ This uses **micro-file architecture** for disciplined execution:
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
|
|
|
|||
|
|
@ -42,9 +42,14 @@ description: 'Critical validation workflow that assesses PRD, Architecture, and
|
|||
|
||||
## INITIALIZATION SEQUENCE
|
||||
|
||||
### 1. Module Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {project-root}/_bmad/bmm/config.yaml and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`, `communication_language`, `document_output_language`
|
||||
- ✅ YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
|
||||
|
|
|
|||
|
|
@ -25,7 +25,14 @@ This uses **micro-file architecture** for disciplined execution:
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,12 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {project-root}/_bmad/bmm/config.yaml and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `planning_artifacts`, `user_name`, `communication_language`, `document_output_language`
|
||||
- ✅ YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
|
||||
|
|
|
|||
|
|
@ -16,6 +16,21 @@
|
|||
|
||||
|
||||
<step n="1" goal="Load story and discover changes">
|
||||
<check if="{project-root}/_bmad/.current_project exists">
|
||||
<action>Read content as project_suffix</action>
|
||||
<!-- Sanitization and Validation -->
|
||||
<action>Trim whitespace and newlines from project_suffix</action>
|
||||
<check if="project_suffix contains '..' or starts with '/' or starts with '\'">
|
||||
<output>🚫 Security Error: Invalid project context path detected.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix matches regex '[^a-zA-Z0-9._-]|^\s*$'">
|
||||
<output>🚫 Error: Project context must only contain alphanumeric characters, dots, dashes, or underscores.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<action>Override output_folder to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
</check>
|
||||
|
||||
<action>Use provided {{story_path}} or ask user which story file to review</action>
|
||||
<action>Read COMPLETE story file</action>
|
||||
<action>Set {{story_key}} = extracted key from filename (e.g., "1-2-user-authentication.md" → "1-2-user-authentication") or story
|
||||
|
|
@ -41,6 +56,7 @@
|
|||
|
||||
<invoke-protocol name="discover_inputs" />
|
||||
<action>Load {project_context} for coding standards (if exists)</action>
|
||||
|
||||
</step>
|
||||
|
||||
<step n="2" goal="Build review attack plan">
|
||||
|
|
|
|||
|
|
@ -40,6 +40,14 @@
|
|||
- [x] Done - Item completed successfully
|
||||
- [N/A] Skip - Item not applicable to this change
|
||||
- [!] Action-needed - Item requires attention or follow-up
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
<action>Maintain running notes of findings and impacts discovered</action>
|
||||
<action>Present checklist progress after each major section</action>
|
||||
|
||||
|
|
|
|||
|
|
@ -18,6 +18,22 @@
|
|||
<critical>🎯 ZERO USER INTERVENTION: Process should be fully automated except for initial epic/story selection or missing documents</critical>
|
||||
|
||||
<step n="1" goal="Determine target story">
|
||||
<check if="{project-root}/_bmad/.current_project exists">
|
||||
<action>Read content as project_suffix</action>
|
||||
<!-- Sanitization and Validation -->
|
||||
<action>Trim whitespace and newlines from project_suffix</action>
|
||||
<check if="project_suffix contains '..' or starts with '/' or starts with '\'">
|
||||
<output>🚫 Security Error: Invalid project context path detected.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix matches regex '[^a-zA-Z0-9._-]|^\s*$'">
|
||||
<output>🚫 Error: Project context must only contain alphanumeric characters, dots, dashes, or underscores.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<action>Override output_folder to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
<action>Output "Monorepo context detected. Output folder redirected to: {output_folder}"</action>
|
||||
</check>
|
||||
|
||||
<check if="{{story_path}} is provided by user or user provided the epic and story number such as 2-4 or 1.6 or epic 1 story 5">
|
||||
<action>Parse user-provided story path: extract epic_num, story_num, story_title from format like "1-2-user-auth"</action>
|
||||
<action>Set {{epic_num}}, {{story_num}}, {{story_key}} from user input</action>
|
||||
|
|
@ -260,48 +276,52 @@
|
|||
<step n="5" goal="Create comprehensive story file">
|
||||
<critical>📝 CREATE ULTIMATE STORY FILE - The developer's master implementation guide!</critical>
|
||||
|
||||
<!-- Recompute output file path with correct output_folder and story_key -->
|
||||
<action>Set {target_story_file} = {output_folder}/{story_key}.md</action>
|
||||
<action>Output "Generating story file at: {target_story_file}"</action>
|
||||
|
||||
<action>Initialize from template.md:
|
||||
{default_output_file}</action>
|
||||
<template-output file="{default_output_file}">story_header</template-output>
|
||||
{target_story_file}</action>
|
||||
<template-output file="{target_story_file}">story_header</template-output>
|
||||
|
||||
<!-- Story foundation from epics analysis -->
|
||||
<template-output
|
||||
file="{default_output_file}">story_requirements</template-output>
|
||||
file="{target_story_file}">story_requirements</template-output>
|
||||
|
||||
<!-- Developer context section - MOST IMPORTANT PART -->
|
||||
<template-output file="{default_output_file}">
|
||||
developer_context_section</template-output> **DEV AGENT GUARDRAILS:** <template-output file="{default_output_file}">
|
||||
<template-output file="{target_story_file}">
|
||||
developer_context_section</template-output> **DEV AGENT GUARDRAILS:** <template-output file="{target_story_file}">
|
||||
technical_requirements</template-output>
|
||||
<template-output file="{default_output_file}">architecture_compliance</template-output>
|
||||
<template-output file="{target_story_file}">architecture_compliance</template-output>
|
||||
<template-output
|
||||
file="{default_output_file}">library_framework_requirements</template-output>
|
||||
<template-output file="{default_output_file}">
|
||||
file="{target_story_file}">library_framework_requirements</template-output>
|
||||
<template-output file="{target_story_file}">
|
||||
file_structure_requirements</template-output>
|
||||
<template-output file="{default_output_file}">testing_requirements</template-output>
|
||||
<template-output file="{target_story_file}">testing_requirements</template-output>
|
||||
|
||||
<!-- Previous story intelligence -->
|
||||
<check
|
||||
if="previous story learnings available">
|
||||
<template-output file="{default_output_file}">previous_story_intelligence</template-output>
|
||||
<template-output file="{target_story_file}">previous_story_intelligence</template-output>
|
||||
</check>
|
||||
|
||||
<!-- Git intelligence -->
|
||||
<check
|
||||
if="git analysis completed">
|
||||
<template-output file="{default_output_file}">git_intelligence_summary</template-output>
|
||||
<template-output file="{target_story_file}">git_intelligence_summary</template-output>
|
||||
</check>
|
||||
|
||||
<!-- Latest technical specifics -->
|
||||
<check if="web research completed">
|
||||
<template-output file="{default_output_file}">latest_tech_information</template-output>
|
||||
<template-output file="{target_story_file}">latest_tech_information</template-output>
|
||||
</check>
|
||||
|
||||
<!-- Project context reference -->
|
||||
<template-output
|
||||
file="{default_output_file}">project_context_reference</template-output>
|
||||
file="{target_story_file}">project_context_reference</template-output>
|
||||
|
||||
<!-- Final status update -->
|
||||
<template-output file="{default_output_file}">
|
||||
<template-output file="{target_story_file}">
|
||||
story_completion_status</template-output>
|
||||
|
||||
<!-- CRITICAL: Set status to ready-for-dev -->
|
||||
|
|
|
|||
|
|
@ -13,6 +13,25 @@
|
|||
<critical>User skill level ({user_skill_level}) affects conversation style ONLY, not code updates.</critical>
|
||||
|
||||
<step n="1" goal="Find next ready story and load it" tag="sprint-status">
|
||||
<check if="{project-root}/_bmad/.current_project exists">
|
||||
<action>Read content as project_suffix</action>
|
||||
<!-- Sanitization and Validation -->
|
||||
<action>Trim whitespace and newlines from project_suffix</action>
|
||||
<check if="project_suffix contains '..' or starts with '/' or starts with '\'">
|
||||
<output>🚫 Security Error: Invalid project context path detected.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix matches regex '[^a-zA-Z0-9._-]|^\s*$'">
|
||||
<output>🚫 Error: Project context must only contain alphanumeric characters, dots, dashes, or underscores.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix.length > 100">
|
||||
<output>🚫 Error: Project context name is too long (max 100 characters).</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<action>Override output_folder to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
</check>
|
||||
|
||||
<check if="{{story_path}} is provided">
|
||||
<action>Use {{story_path}} directly</action>
|
||||
<action>Read COMPLETE story file</action>
|
||||
|
|
@ -376,8 +395,6 @@
|
|||
|
||||
<action>Communicate to {user_name} that story implementation is complete and ready for review</action>
|
||||
<action>Summarize key accomplishments: story ID, story key, title, key changes made, tests added, files modified</action>
|
||||
<action>Provide the story file path and current status (now "review")</action>
|
||||
|
||||
<action>Based on {user_skill_level}, ask if user needs any explanations about:
|
||||
- What was implemented and how it works
|
||||
- Why certain technical decisions were made
|
||||
|
|
|
|||
|
|
@ -1,7 +1,20 @@
|
|||
# Retrospective - Epic Completion Review Instructions
|
||||
|
||||
<critical>The workflow execution engine is governed by: {project-root}/_bmad/core/tasks/workflow.xml</critical>
|
||||
<critical>You MUST have already loaded and processed: {project-root}/_bmad/bmm/workflows/4-implementation/retrospective/workflow.yaml</critical>
|
||||
<critical>You MUST have already loaded and processed: {installed_path}/workflow.yaml</critical>
|
||||
|
||||
## 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
3. Re-derive dependent path variables to reflect the new `output_folder`:
|
||||
- `implementation_artifacts`: `{output_folder}/implementation`
|
||||
- `planning_artifacts`: `{output_folder}/planning`
|
||||
|
||||
<critical>Communicate all responses in {communication_language} and language MUST be tailored to {user_skill_level}</critical>
|
||||
<critical>Generate all documents in {document_output_language}</critical>
|
||||
<critical>⚠️ ABSOLUTELY NO TIME ESTIMATES - NEVER mention hours, days, weeks, months, or ANY time-based predictions. AI has fundamentally changed development speed - what once took teams weeks/months can now be done by one person in hours. DO NOT give ANY time estimates whatsoever.</critical>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,17 @@
|
|||
<critical>The workflow execution engine is governed by: {project-root}/_bmad/core/tasks/workflow.xml</critical>
|
||||
<critical>You MUST have already loaded and processed: {project-root}/_bmad/bmm/workflows/4-implementation/sprint-planning/workflow.yaml</critical>
|
||||
|
||||
## 📚 Document Discovery - Full Epic Loading
|
||||
## 📚 Document Discovery
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- Full Epic Loading
|
||||
|
||||
**Strategy**: Sprint planning needs ALL epics and stories to build complete status tracking.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,15 @@
|
|||
# Sprint Status - Multi-Mode Service
|
||||
|
||||
<critical>The workflow execution engine is governed by: {project-root}/_bmad/core/tasks/workflow.xml</critical>
|
||||
|
||||
## 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
<critical>You MUST have already loaded and processed: {project-root}/_bmad/bmm/workflows/4-implementation/sprint-status/workflow.yaml</critical>
|
||||
<critical>Modes: interactive (default), validate, data</critical>
|
||||
<critical>⚠️ ABSOLUTELY NO TIME ESTIMATES. Do NOT mention hours, days, weeks, or timelines.</critical>
|
||||
|
|
|
|||
|
|
@ -23,7 +23,14 @@ This uses **step-file architecture** for focused execution:
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
|
||||
|
|
|
|||
|
|
@ -66,8 +66,14 @@ This uses **step-file architecture** for disciplined execution:
|
|||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from `{main_config}` and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
- `project_name`, `planning_artifacts`, `implementation_artifacts`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
- `date` as system-generated current datetime
|
||||
|
|
|
|||
|
|
@ -79,6 +79,15 @@
|
|||
|
||||
</step>
|
||||
|
||||
## 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
<step n="3" goal="Check for existing documentation and determine workflow mode" if="resume_mode == false">
|
||||
<action>Check if {project_knowledge}/index.md exists</action>
|
||||
|
||||
|
|
|
|||
|
|
@ -11,6 +11,23 @@
|
|||
<action>Load existing project structure from index.md and project-parts.json (if exists)</action>
|
||||
<action>Load source tree analysis to understand available areas</action>
|
||||
|
||||
<check if="{project-root}/_bmad/.current_project exists">
|
||||
<action>Read content as project_suffix</action>
|
||||
<!-- Sanitization and Validation -->
|
||||
<action>Trim whitespace and newlines from project_suffix</action>
|
||||
<check if="project_suffix contains '..' or starts with '/' or starts with '\'">
|
||||
<output>🚫 Security Error: Invalid project context path detected.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix matches regex '[^a-zA-Z0-9._-]|^\s*$'">
|
||||
<output>🚫 Error: Project context must only contain alphanumeric characters, dots, dashes, or underscores.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<action>Override output_folder to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
<action>Override project_knowledge to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
<action>Output "Monorepo context detected. Writing deep-dive artifacts to: {project_knowledge}"</action>
|
||||
</check>
|
||||
|
||||
<step n="13a" goal="Identify area for deep-dive">
|
||||
<action>Analyze existing documentation to suggest deep-dive options</action>
|
||||
|
||||
|
|
@ -250,8 +267,11 @@ Detailed exhaustive analysis of specific areas:
|
|||
|
||||
- Complete file inventory with all exports
|
||||
- Dependency graph and data flow
|
||||
- Integration points and API contracts
|
||||
- Testing analysis and coverage
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
|
||||
- Related code and reuse opportunities
|
||||
- Implementation guidance
|
||||
|
||||
|
|
|
|||
|
|
@ -95,6 +95,16 @@ Your choice [1/2/3]:
|
|||
- Best for: Quick project overview, initial understanding
|
||||
- File reading: Minimal (configs, README, package.json, etc.)
|
||||
|
||||
## 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
json, etc.)
|
||||
|
||||
**2. Deep Scan** (10-30 minutes)
|
||||
|
||||
- Reads files in critical directories based on project type
|
||||
|
|
|
|||
|
|
@ -25,7 +25,14 @@ This uses **micro-file architecture** for disciplined execution:
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
Load config from `{project-root}/_bmad/bmm/config.yaml` and resolve:
|
||||
|
||||
|
|
|
|||
|
|
@ -18,6 +18,15 @@ Check project for existing test framework:
|
|||
- Search online for current recommended test framework for that stack
|
||||
- Suggest the meta framework and use it (or ask user to confirm)
|
||||
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
### Step 1: Identify Features
|
||||
|
||||
Ask user what to test:
|
||||
|
|
|
|||
|
|
@ -20,6 +20,21 @@
|
|||
|
||||
<flow>
|
||||
<step n="1" title="Method Registry Loading">
|
||||
<check if="{project-root}/_bmad/.current_project exists">
|
||||
<action>Read content as project_suffix</action>
|
||||
<!-- Sanitization and Validation -->
|
||||
<action>Trim whitespace and newlines from project_suffix</action>
|
||||
<check if="project_suffix contains '..' or starts with '/' or starts with '\'">
|
||||
<output>🚫 Security Error: Invalid project context path detected.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<check if="project_suffix matches regex '[^a-zA-Z0-9._-]|^\s*$'">
|
||||
<output>🚫 Error: Project context must only contain alphanumeric characters, dots, dashes, or underscores.</output>
|
||||
<action>HALT</action>
|
||||
</check>
|
||||
<action>Override output_folder to {project-root}/_bmad-output/{project_suffix}</action>
|
||||
</check>
|
||||
|
||||
<action>Load and read {{methods}} and {{agent-party}}</action>
|
||||
|
||||
<csv-structure>
|
||||
|
|
|
|||
|
|
@ -32,7 +32,14 @@ This uses **micro-file architecture** for disciplined execution:
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
Load config from `{project-root}/_bmad/core/config.yaml` and resolve:
|
||||
|
||||
|
|
|
|||
|
|
@ -25,9 +25,14 @@ This uses **micro-file architecture** with **sequential conversation orchestrati
|
|||
|
||||
## INITIALIZATION
|
||||
|
||||
### Configuration Loading
|
||||
### 1. Configuration Loading
|
||||
|
||||
Load config from `{project-root}/_bmad/core/config.yaml` and resolve:
|
||||
Load and read full config from {main_config} and resolve basic variables.
|
||||
|
||||
**Monorepo Context Check:**
|
||||
1. Check if `{project-root}/_bmad/.current_project` exists.
|
||||
2. If it exists, read its content as `{project_suffix}` and override output folder:
|
||||
- `output_folder`: `{project-root}/_bmad-output/{project_suffix}`
|
||||
|
||||
- `project_name`, `output_folder`, `user_name`
|
||||
- `communication_language`, `document_output_language`, `user_skill_level`
|
||||
|
|
|
|||
|
|
@ -0,0 +1,129 @@
|
|||
/**
|
||||
* Monorepo Support Validation Tests
|
||||
*
|
||||
* Verifies that:
|
||||
* 1. The set-project workflow is correctly registered.
|
||||
* 2. All core and BMM workflows contain the monorepo context logic.
|
||||
*/
|
||||
|
||||
const fs = require('fs-extra');
|
||||
const path = require('node:path');
|
||||
const glob = require('glob');
|
||||
|
||||
// ANSI colors
|
||||
const colors = {
|
||||
reset: '\u001B[0m',
|
||||
green: '\u001B[32m',
|
||||
red: '\u001B[31m',
|
||||
yellow: '\u001B[33m',
|
||||
cyan: '\u001B[36m',
|
||||
dim: '\u001B[2m',
|
||||
};
|
||||
|
||||
let passed = 0;
|
||||
let failed = 0;
|
||||
|
||||
function assert(condition, testName, errorMessage = '') {
|
||||
if (condition) {
|
||||
console.log(`${colors.green}✓${colors.reset} ${testName}`);
|
||||
passed++;
|
||||
} else {
|
||||
console.log(`${colors.red}✗${colors.reset} ${testName}`);
|
||||
if (errorMessage) {
|
||||
console.log(` ${colors.dim}${errorMessage}${colors.reset}`);
|
||||
}
|
||||
failed++;
|
||||
}
|
||||
}
|
||||
|
||||
async function runTests() {
|
||||
console.log(`${colors.cyan}========================================`);
|
||||
console.log('Monorepo Support Validation Tests');
|
||||
console.log(`========================================${colors.reset}\n`);
|
||||
|
||||
const projectRoot = path.join(__dirname, '..');
|
||||
|
||||
// 1. Verify set-project registration
|
||||
console.log(`${colors.yellow}Test Suite 1: Workflow Registration${colors.reset}\n`);
|
||||
try {
|
||||
const csvPath = path.join(projectRoot, 'src/bmm/module-help.csv');
|
||||
const content = await fs.readFile(csvPath, 'utf8');
|
||||
assert(content.includes('set-project'), 'set-project workflow is registered in module-help.csv');
|
||||
} catch (error) {
|
||||
assert(false, 'Registration check failed', error.message);
|
||||
}
|
||||
|
||||
console.log('');
|
||||
|
||||
// 2. Verify context logic in workflows
|
||||
console.log(`${colors.yellow}Test Suite 2: Workflow Context Logic${colors.reset}\n`);
|
||||
|
||||
const workflowFiles = glob.sync('src/{core,bmm}/workflows/**/*.{md,xml}', { cwd: projectRoot });
|
||||
|
||||
// Workflows that MUST have the check
|
||||
const requiredWorkflows = [
|
||||
'brainstorming',
|
||||
'party-mode',
|
||||
'create-product-brief',
|
||||
'create-prd',
|
||||
'create-architecture',
|
||||
'code-review',
|
||||
'create-story',
|
||||
'dev-story',
|
||||
'set-project', // Should not have the check itself, but let's exclude it
|
||||
];
|
||||
|
||||
for (const file of workflowFiles) {
|
||||
const basename = path.basename(path.dirname(file));
|
||||
if (basename === 'set-project' || basename === '0-context') continue;
|
||||
|
||||
const content = await fs.readFile(path.join(projectRoot, file), 'utf8');
|
||||
const isXml = file.endsWith('.xml');
|
||||
|
||||
if (isXml) {
|
||||
assert(content.includes('_bmad/.current_project'), `XML workflow contains context check: ${file}`);
|
||||
} else {
|
||||
// Only check Markdown files that look like main workflow/instruction files
|
||||
const filename = path.basename(file);
|
||||
if (filename.includes('workflow') || filename.includes('instructions')) {
|
||||
assert(content.includes('_bmad/.current_project'), `Markdown workflow contains context check: ${file}`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
console.log('');
|
||||
|
||||
// 3. Verify set-project implementation
|
||||
console.log(`${colors.yellow}Test Suite 3: set-project Implementation${colors.reset}\n`);
|
||||
try {
|
||||
const setProjectPath = path.join(projectRoot, 'src/bmm/workflows/0-context/set-project/workflow.md');
|
||||
const exists = await fs.pathExists(setProjectPath);
|
||||
assert(exists, 'set-project workflow file exists');
|
||||
if (exists) {
|
||||
const content = await fs.readFile(setProjectPath, 'utf8');
|
||||
assert(content.includes('_bmad/.current_project'), 'set-project implementation manages .current_project');
|
||||
}
|
||||
} catch (error) {
|
||||
assert(false, 'set-project check failed', error.message);
|
||||
}
|
||||
|
||||
console.log('\n');
|
||||
console.log(`${colors.cyan}========================================`);
|
||||
console.log('Test Results:');
|
||||
console.log(` Passed: ${colors.green}${passed}${colors.reset}`);
|
||||
console.log(` Failed: ${colors.red}${failed}${colors.reset}`);
|
||||
console.log(`========================================${colors.reset}\n`);
|
||||
|
||||
if (failed === 0) {
|
||||
console.log(`${colors.green}✨ All monorepo validation tests passed!${colors.reset}\n`);
|
||||
process.exit(0);
|
||||
} else {
|
||||
console.log(`${colors.red}❌ Some monorepo validation tests failed${colors.reset}\n`);
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
runTests().catch((error) => {
|
||||
console.error(error);
|
||||
process.exit(1);
|
||||
});
|
||||
|
|
@ -437,9 +437,9 @@ tools: ${toolsStr}
|
|||
- **Communication Language**: ${configVars.communication_language || '{{communication_language}}'}
|
||||
- **Document Output Language**: ${configVars.document_output_language || '{{document_output_language}}'}
|
||||
- **User Skill Level**: ${configVars.user_skill_level || '{{user_skill_level}}'}
|
||||
- **Output Folder**: ${configVars.output_folder || '{{output_folder}}'}
|
||||
- **Planning Artifacts**: ${configVars.planning_artifacts || '{{planning_artifacts}}'}
|
||||
- **Implementation Artifacts**: ${configVars.implementation_artifacts || '{{implementation_artifacts}}'}
|
||||
- **Output Folder**: ${configVars.output_folder || '{{output_folder}}'}/{context} (Dynamic)
|
||||
- **Planning Artifacts**: ${configVars.planning_artifacts || '{{planning_artifacts}}'}/{context} (Dynamic)
|
||||
- **Implementation Artifacts**: ${configVars.implementation_artifacts || '{{implementation_artifacts}}'}/{context} (Dynamic)
|
||||
- **Project Knowledge**: ${configVars.project_knowledge || '{{project_knowledge}}'}
|
||||
|
||||
## BMAD Runtime Structure
|
||||
|
|
|
|||
Loading…
Reference in New Issue