Débutant
Module 2 — BMAD : démarrer et lancer ton premier cycle
Temps de pratique : 20 min
Objectif
À la fin de ce module, tu auras installé BMAD, créé un project-context.md, et passé une story complète (create → dev → review).
Quand utiliser BMAD
| Scénario | Track | Durée |
|---|---|---|
| Bugfix, script, tâche isolée | Quick Flow | 5–15 min |
| Feature complète, MVP | BMAD Method | 30 min – 2 h |
| Système critique, compliance | Enterprise | 2 h – journée |
Prérequis
- Node.js ≥ 20.12 (
node -v) - Python ≥ 3.10
- uv (
uv --version) - Git initialisé (
git init)
Étape 1 — Installation
npx bmad-method install
Sélectionne BMad Method quand l’installateur te le demande.
Vérifie :
npx bmad-method doctor
Étape 2 — Remplir le project-context.md
C’est la constitution de ton projet. Sans ça, les agents devinent et se trompent.
cat > _bmad-output/project-context.md << 'EOF'
## Technology Stack & Versions
- Node.js 20.x, TypeScript 5.3, React 18.2
- State: Zustand (not Redux)
- Testing: Vitest, Playwright, MSW
- Styling: Tailwind CSS with custom design tokens
## Critical Implementation Rules
**TypeScript Configuration:**
- Strict mode enabled — no `any` types without explicit approval
- Use `interface` for public APIs, `type` for unions/intersections
**Code Organization:**
- Components in `/src/components/` with co-located `.test.tsx`
- Utilities in `/src/lib/` for reusable pure functions
- API calls use the `apiClient` singleton — never fetch directly
**Testing Patterns:**
- Unit tests focus on business logic, not implementation details
- Integration tests use MSW to mock API responses
- E2E tests cover critical user journeys only
EOF
Étape 3 — Lancer le cycle
3a. Créer la story
npx bmad-method create-story
Réponds aux questions :
- Titre : “Ajouter l’authentification JWT”
- Description : “Permettre aux utilisateurs de se connecter avec email/mot de passe et recevoir un token JWT”
- Track :
bmad-method
BMAD génère .bmad/stories/001-auth-jwt/story.md avec les 4 phases.
3b. Développer la story
npx bmad-method dev-story --id 001
L’agent Dev génère le code. Relis le diff avant d’accepter :
y= appliquer le fichiern= ignorerr= demander une révision
3c. Code review
npx bmad-method code-review --id 001
L’agent QA vérifie :
- Conformité au
project-context.md - Patterns de sécurité
- Cohérence architecture
Le cycle complet en résumé
@diagram:bmad-cycle
Checklist de validation
-
npx bmad-method installexécuté sans erreur -
project-context.mdrempli avec Stack + Rules - Une story créée via
create-story - La story développée via
dev-story - Le code review passé via
code-review - Le code relu avant application
Piège courant
Le project-context.md est vide. → Les agents produisent du boilerplate hors scope. 10 min de rédaction = 2h de corrections en moins.
Prochaine étape
→ Module 6 (BMAD — Tracks avancés) pour maîtriser Quick Flow vs Enterprise