@atlashub/smartstack-cli 1.11.0 → 1.12.0

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.
Files changed (74) hide show
  1. package/.documentation/agents.html +7 -2
  2. package/.documentation/apex.html +7 -2
  3. package/.documentation/business-analyse.html +7 -2
  4. package/.documentation/cli-commands.html +871 -0
  5. package/.documentation/commands.html +7 -2
  6. package/.documentation/efcore.html +7 -2
  7. package/.documentation/gitflow.html +7 -2
  8. package/.documentation/hooks.html +7 -2
  9. package/.documentation/index.html +7 -2
  10. package/.documentation/init.html +7 -2
  11. package/.documentation/installation.html +7 -2
  12. package/.documentation/ralph-loop.html +7 -2
  13. package/.documentation/test-web.html +7 -2
  14. package/dist/index.js +1932 -336
  15. package/dist/index.js.map +1 -1
  16. package/package.json +8 -2
  17. package/templates/agents/efcore/squash.md +67 -31
  18. package/templates/agents/gitflow/finish.md +68 -56
  19. package/templates/commands/business-analyse/0-orchestrate.md +72 -556
  20. package/templates/commands/business-analyse/1-init.md +23 -193
  21. package/templates/commands/business-analyse/2-discover.md +85 -462
  22. package/templates/commands/business-analyse/3-analyse.md +40 -342
  23. package/templates/commands/business-analyse/4-specify.md +72 -537
  24. package/templates/commands/business-analyse/5-validate.md +43 -237
  25. package/templates/commands/business-analyse/6-handoff.md +93 -682
  26. package/templates/commands/business-analyse/7-doc-html.md +45 -544
  27. package/templates/commands/business-analyse/_shared.md +176 -0
  28. package/templates/commands/business-analyse/bug.md +50 -257
  29. package/templates/commands/business-analyse/change-request.md +59 -283
  30. package/templates/commands/business-analyse/hotfix.md +36 -120
  31. package/templates/commands/business-analyse.md +55 -574
  32. package/templates/commands/efcore/_shared.md +206 -0
  33. package/templates/commands/efcore/conflicts.md +39 -201
  34. package/templates/commands/efcore/db-deploy.md +28 -237
  35. package/templates/commands/efcore/db-reset.md +41 -390
  36. package/templates/commands/efcore/db-seed.md +44 -323
  37. package/templates/commands/efcore/db-status.md +31 -210
  38. package/templates/commands/efcore/migration.md +45 -368
  39. package/templates/commands/efcore/rebase-snapshot.md +38 -241
  40. package/templates/commands/efcore/scan.md +35 -204
  41. package/templates/commands/efcore/squash.md +158 -251
  42. package/templates/commands/efcore.md +49 -177
  43. package/templates/commands/gitflow/1-init.md +94 -1318
  44. package/templates/commands/gitflow/10-start.md +86 -990
  45. package/templates/commands/gitflow/11-finish.md +264 -454
  46. package/templates/commands/gitflow/12-cleanup.md +40 -213
  47. package/templates/commands/gitflow/2-status.md +51 -386
  48. package/templates/commands/gitflow/3-commit.md +108 -801
  49. package/templates/commands/gitflow/4-plan.md +42 -13
  50. package/templates/commands/gitflow/5-exec.md +60 -5
  51. package/templates/commands/gitflow/6-abort.md +54 -277
  52. package/templates/commands/gitflow/7-pull-request.md +74 -717
  53. package/templates/commands/gitflow/8-review.md +51 -178
  54. package/templates/commands/gitflow/9-merge.md +74 -404
  55. package/templates/commands/gitflow/_shared.md +196 -0
  56. package/templates/commands/quickstart.md +154 -0
  57. package/templates/commands/ralph-loop/ralph-loop.md +104 -2
  58. package/templates/hooks/hooks.json +13 -0
  59. package/templates/hooks/ralph-mcp-logger.sh +46 -0
  60. package/templates/hooks/ralph-session-end.sh +69 -0
  61. package/templates/ralph/README.md +91 -0
  62. package/templates/ralph/ralph.config.yaml +113 -0
  63. package/templates/scripts/setup-ralph-loop.sh +173 -0
  64. package/templates/skills/_shared.md +117 -0
  65. package/templates/skills/ai-prompt/SKILL.md +87 -654
  66. package/templates/skills/application/SKILL.md +76 -499
  67. package/templates/skills/controller/SKILL.md +38 -165
  68. package/templates/skills/documentation/SKILL.md +2 -1
  69. package/templates/skills/feature-full/SKILL.md +107 -732
  70. package/templates/skills/notification/SKILL.md +85 -474
  71. package/templates/skills/ui-components/SKILL.md +62 -762
  72. package/templates/skills/workflow/SKILL.md +85 -489
  73. package/templates/commands/gitflow/rescue.md +0 -867
  74. package/templates/skills/business-analyse/SKILL.md +0 -191
@@ -4,164 +4,78 @@ description: EF Core Commands - Migration and database management
4
4
 
5
5
  # EF Core Commands
6
6
 
7
- Set of commands to manage Entity Framework Core: migrations, database, and seeding.
7
+ > **Ref:** Fonctions communes dans [efcore/_shared.md](efcore/_shared.md)
8
+ > **MCP:** `mcp__smartstack__check_migrations` pour analyse conflits
8
9
 
9
- > **MCP INTEGRATION:** Commands use `mcp__smartstack__check_migrations` for conflict analysis and validation.
10
+ ---
10
11
 
11
- ## Available Commands
12
+ ## Commandes Disponibles
12
13
 
13
14
  ### Migrations
14
15
 
15
- | Command | Description | Risk |
16
- |---------|-------------|------|
17
- | `/efcore:migration` | Create/recreate migration (1 per feature) | Low |
18
- | `/efcore:db-status` | Show migration status | None (read-only) |
19
- | `/efcore:db-deploy` | Apply migrations | Low |
20
- | `/efcore:db-seed` | Populate with data | Low |
21
- | `/efcore:db-reset` | Drop + Recreate database | **HIGH** |
22
-
23
- ### Cross-Branch (v1.2)
24
-
25
- | Command | Description | Risk |
26
- |---------|-------------|------|
27
- | `/efcore:scan` | Scan migrations across all branches | None (read-only) |
28
- | `/efcore:conflicts` | Analyze potential conflicts (BLOCKING) | None (read-only) |
29
- | `/efcore:rebase-snapshot` | Rebase ModelSnapshot on develop | Medium |
30
- | `/efcore:squash` | Merge multiple migrations into one | **HIGH** |
31
-
32
- ## Golden Rule: 1 Migration per Feature
16
+ | Commande | Description | Risque |
17
+ |----------|-------------|--------|
18
+ | `/efcore:migration` | Créer/recréer migration (1 par feature) | Low |
19
+ | `/efcore:db-status` | Afficher statut migrations | None |
20
+ | `/efcore:db-deploy` | Appliquer migrations | Low |
21
+ | `/efcore:db-seed` | Peupler avec données | Low |
22
+ | `/efcore:db-reset` | Drop + Recreate DB | **HIGH** |
33
23
 
34
- **Never accumulate multiple migrations on a feature.** If you modify the model:
35
- 1. Delete the existing migration
36
- 2. Recreate it with `/efcore:migration`
24
+ ### Cross-Branch
37
25
 
38
- The `/efcore:migration` command handles this automatically.
26
+ | Commande | Description | Risque |
27
+ |----------|-------------|--------|
28
+ | `/efcore:scan` | Scanner toutes les branches | None |
29
+ | `/efcore:conflicts` | Analyser conflits (BLOQUANT) | None |
30
+ | `/efcore:rebase-snapshot` | Rebaser ModelSnapshot sur develop | Medium |
31
+ | `/efcore:squash` | Fusionner migrations | **HIGH** |
39
32
 
40
- ## Migration Naming
33
+ ---
41
34
 
42
- Pattern: `{context}_v{version}_{sequence}_{Description}` (aligned with SmartStack MCP)
35
+ ## Règle d'Or: 1 Migration par Feature
43
36
 
44
- | Context | Version | Sequence | Description | Generated Name |
45
- |---------|---------|----------|-------------|----------------|
46
- | core | 1.2.0 | 001 | AddUserRoles | `core_v1.2.0_001_AddUserRoles` |
47
- | core | 1.2.0 | 002 | AddPermissions | `core_v1.2.0_002_AddPermissions` |
48
- | extensions | 1.3.0 | 001 | AddCustomFields | `extensions_v1.3.0_001_AddCustomFields` |
37
+ Si modification du modèle: supprimer et recréer la migration.
49
38
 
50
- > **Note:** Context is `core` for SmartStack platform tables, `extensions` for client-specific extensions.
39
+ ---
51
40
 
52
- ## Typical Workflow
41
+ ## Workflow Typique
53
42
 
54
43
  ```
55
- 1. /gitflow:10-start feature xxx → Create worktree + appsettings.Local.json
56
- 2. /efcore:db-deploy → Apply existing migrations
57
- 3. ... model modifications ...
58
- 4. /efcore:migration → Create THE migration for this feature
59
- 5. /efcore:db-deploy → Apply to local DB
44
+ 1. /gitflow:10-start feature xxx → Worktree + appsettings.Local.json
45
+ 2. /efcore:db-deploy → Appliquer migrations existantes
46
+ 3. ... modifications modèle ...
47
+ 4. /efcore:migration → Créer LA migration
48
+ 5. /efcore:db-deploy → Appliquer localement
60
49
  6. /gitflow:3-commit → Commit
61
50
  ```
62
51
 
63
- ## Cross-Branch Workflow (v1.2)
64
-
65
- With GitFlow worktrees, multiple branches can have migrations in parallel. To avoid conflicts:
66
-
67
- ```
68
- 1. /efcore:scan → Scan all active branches
69
- 2. /efcore:conflicts → Check for conflicts (BLOCKING)
70
- 3. /efcore:rebase-snapshot → If conflict, rebase on develop
71
- 4. /efcore:migration → Create/recreate migration
72
- ```
73
-
74
- ### Recommended Merge Order
75
-
76
- The scan analyzes migrations and recommends a merge order:
77
-
78
- ```
79
- ACTIVE BRANCHES (3)
80
- --------------------
81
- feature/user-roles +1 migration Conflict: NONE
82
- feature/add-products +1 migration Conflict: POTENTIAL
83
- feature/orders +2 migrations Conflict: HIGH
84
-
85
- RECOMMENDED MERGE ORDER:
86
- 1. feature/user-roles (independent)
87
- 2. feature/add-products (before orders)
88
- 3. feature/orders (rebase required)
89
- ```
90
-
91
- ## Configuration
92
-
93
- Commands use configuration in `.claude/gitflow/config.json`:
94
-
95
- ```json
96
- {
97
- "efcore": {
98
- "database": {
99
- "configFile": "appsettings.Local.json",
100
- "connectionStringName": "DefaultConnection",
101
- "provider": "SqlServer"
102
- },
103
- "crossBranch": {
104
- "enabled": true,
105
- "scanOnMigrationCreate": true,
106
- "blockOnConflict": true,
107
- "cacheExpiry": 300
108
- }
109
- }
110
- }
111
- ```
112
-
113
- ### crossBranch Options
114
-
115
- | Option | Description | Default |
116
- |--------|-------------|---------|
117
- | `enabled` | Enable cross-branch validation | `true` |
118
- | `scanOnMigrationCreate` | Scan before `/efcore:migration` | `true` |
119
- | `blockOnConflict` | Block if conflict detected | `true` |
120
- | `cacheExpiry` | Scan cache duration (seconds) | `300` |
121
-
122
- ## Environment Selection (NEW)
52
+ ---
123
53
 
124
- All EF Core commands now display the target database BEFORE execution:
54
+ ## Workflow Cross-Branch
125
55
 
126
56
  ```
127
- ================================================================================
128
- EF CORE - DATABASE DEPLOY
129
- ================================================================================
130
-
131
- FICHIERS DISPONIBLES:
132
- - appsettings.json
133
- - appsettings.Local.json
134
- - appsettings.Development.json
135
-
136
- ENVIRONNEMENT: appsettings.Local.json
137
-
138
- CONNEXION CIBLE:
139
- Server: localhost
140
- Database: SmartStack_Dev
141
- String: Server=localhost;Database=SmartStack_Dev;...
142
-
143
- ================================================================================
57
+ 1. /efcore:scan → Scanner branches actives
58
+ 2. /efcore:conflicts → Vérifier conflits (BLOQUANT)
59
+ 3. /efcore:rebase-snapshot → Si conflit, rebaser sur develop
60
+ 4. /efcore:migration → Créer/recréer migration
144
61
  ```
145
62
 
146
- ### Override Environment
63
+ ---
147
64
 
148
- Use `--env` flag to target a different environment:
65
+ ## Sélection Environnement
149
66
 
150
- ```bash
151
- # Deploy to Development environment
152
- /efcore:db-deploy --env Development
67
+ Toutes les commandes affichent la base cible AVANT exécution.
153
68
 
154
- # Reset Staging database
155
- /efcore:db-reset --env Staging
156
- ```
69
+ | Priorité | Fichier |
70
+ |----------|---------|
71
+ | 1 | `--env {Environment}` flag |
72
+ | 2 | `appsettings.Local.json` (défaut) |
157
73
 
158
- ### Protection Production
74
+ **Protection:** Commandes destructives bloquées si Production détecté.
159
75
 
160
- Commands that modify the database are **automatically blocked** if `appsettings.Production.json` is detected.
161
-
162
- ## appsettings.Local.json File
76
+ ---
163
77
 
164
- This file contains the local connection string and is **never committed**:
78
+ ## appsettings.Local.json
165
79
 
166
80
  ```json
167
81
  {
@@ -171,54 +85,12 @@ This file contains the local connection string and is **never committed**:
171
85
  }
172
86
  ```
173
87
 
174
- The file is automatically created by `/gitflow:10-start` and added to `.gitignore`.
175
-
176
- ## Prerequisites
177
-
178
- - .NET SDK installed
179
- - EF Core Tools: `dotnet tool install --global dotnet-ef`
180
- - SQL Server (or other configured provider)
88
+ Créé automatiquement par `/gitflow:10-start`, ajouté à `.gitignore`.
181
89
 
182
90
  ---
183
91
 
184
- ## MCP Integration
185
-
186
- The following commands use **SmartStack MCP** for enhanced functionality:
92
+ ## Prérequis
187
93
 
188
- | Command | MCP Tool | Purpose |
189
- |---------|----------|---------|
190
- | `/efcore:db-status` | `check_migrations` | Get structured migration list |
191
- | `/efcore:conflicts` | `check_migrations` | Analyze branch conflicts |
192
- | `/efcore:scan` | `check_migrations` | Multi-branch analysis |
193
-
194
- ### MCP Tool Reference
195
-
196
- **Tool:** `mcp__smartstack__check_migrations`
197
-
198
- **Description:** Analyze EF Core migrations for conflicts, ordering issues, and ModelSnapshot discrepancies between branches.
199
-
200
- **Parameters:**
201
-
202
- | Parameter | Type | Description |
203
- |-----------|------|-------------|
204
- | `projectPath` | string | EF Core project path (default: auto-detect) |
205
- | `branch` | string | Git branch to check (default: current) |
206
- | `compareBranch` | string | Branch to compare against |
207
-
208
- **Response:** `MigrationCheckResult`
209
-
210
- ```typescript
211
- interface MigrationCheckResult {
212
- hasConflicts: boolean;
213
- migrations: MigrationInfo[];
214
- conflicts: MigrationConflict[];
215
- suggestions: string[];
216
- }
217
- ```
218
-
219
- ### Benefits of MCP Integration
220
-
221
- 1. **Consistency:** Same analysis logic in CLI, CI/CD, and IDE
222
- 2. **Structured Data:** Typed responses instead of text parsing
223
- 3. **Single Source of Truth:** Convention rules in MCP config
224
- 4. **Extensibility:** New checks benefit all commands
94
+ - .NET SDK installé
95
+ - EF Core Tools: `dotnet tool install --global dotnet-ef`
96
+ - SQL Server (ou provider configuré)