# {{PROJECT_NAME}} - Symfony

> Genere: {{GENERATION_DATE}} | Claude Craft v{{VERSION}}

## Quoi (Stack & Structure)

**Stack**: {{TECH_STACK}}

### Structure du projet
```
src/
├── Domain/              # Coeur metier (AUCUNE dependance externe)
│   ├── Entity/          # Aggregates roots
│   ├── ValueObject/     # Objets immuables
│   ├── Event/           # Domain Events
│   └── Repository/      # Interfaces repositories
├── Application/         # Use Cases (CQRS)
│   ├── Command/         # Ecriture
│   ├── Query/           # Lecture
│   └── Handler/         # Handlers
└── Infrastructure/      # Details techniques
    ├── Persistence/     # Doctrine implementations
    ├── Http/            # Controllers
    └── Cache/           # Redis
```

## Pourquoi (Objectif & Organisation)

### Architecture: Clean Architecture + DDD + Hexagonale
- **Domain**: Logique metier pure, aucune dependance externe
- **Application**: Orchestration des use cases
- **Infrastructure**: Adaptateurs techniques

Voir `rules/02-architecture-clean-ddd.md` pour les patterns.

### Regles critiques

| Regle | Description |
|-------|-------------|
| Analyse avant code | Consulter `rules/01-workflow-analysis.md` |
| Docker obligatoire | Toutes commandes via `make` |
| TDD strict | RED -> GREEN -> REFACTOR |
| Qualite | `make quality` apres chaque modif |
| Couverture | Tests 80%+ obligatoire |

## Comment (Commandes & Workflows)

### Commandes de developpement
```bash
make up                # Demarrer la stack
make shell             # Shell dans container PHP
make console CMD="..." # Symfony console
make composer CMD="..."# Composer
```

### Pipeline de qualite
```bash
make quality           # PHPStan + CS-Fixer + Rector + Deptrac + Tests
make test              # Tous les tests
make test-coverage     # Rapport couverture HTML
make phpstan           # Analyse statique
make cs-fix            # Fix code style
```

### Base de donnees
```bash
make db-migrate        # Migrations
make db-fixtures       # Fixtures
make db-reset          # Reset complet
```

### Workflow de developpement
1. **Analyser** - `rules/01-workflow-analysis.md`
2. **TDD** - Ecrire test (RED) -> Implementer (GREEN) -> Refactorer
3. **Qualite** - `make quality`
4. **Commit** - Conventional Commits

## References

| Contexte | Fichier |
|----------|---------|
| Workflow | `rules/01-workflow-analysis.md` |
| Architecture | `rules/02-architecture-clean-ddd.md` |
| Standards | `rules/03-coding-standards.md` |
| SOLID | `rules/04-solid-principles.md` |
| KISS/DRY | `rules/05-kiss-dry-yagni.md` |
| Docker | `rules/06-docker-hadolint.md` |
| Tests | `rules/07-testing-tdd-bdd.md` |
| Git | `rules/09-git-workflow.md` |
| Securite | `rules/11-security-rgpd.md` |

<!-- PROJECT-SPECIFIC-START -->
## Specificites du projet

<!-- Cette section est preservee lors des mises a jour -->

<!-- PROJECT-SPECIFIC-END -->
