@roomi-fields/grillhouse 0.0.0-stage → 0.23.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.
- package/.claude-plugin/plugin.json +9 -0
- package/METACADRE.md +41 -0
- package/agents/developpeur.md +10 -0
- package/agents/explorateur.md +9 -0
- package/agents/questionneur.md +11 -0
- package/agents/referent-technique.md +9 -0
- package/agents/regulateur.md +11 -0
- package/agents/relecteur.md +9 -0
- package/agents/testwriter.md +10 -0
- package/bin/grillhouse.mjs +125 -0
- package/cadre/templates/projet/.claude/settings.json +30 -0
- package/cadre/templates/projet/.editorconfig +47 -0
- package/cadre/templates/projet/.env.example +57 -0
- package/cadre/templates/projet/.eslintrc.cjs +56 -0
- package/cadre/templates/projet/.github/workflows/ci.yml +66 -0
- package/cadre/templates/projet/.mcp.json +13 -0
- package/cadre/templates/projet/.prettierrc +11 -0
- package/cadre/templates/projet/CHANGELOG.md +61 -0
- package/cadre/templates/projet/CLAUDE.md +46 -0
- package/cadre/templates/projet/CONTRIBUTING.md +243 -0
- package/cadre/templates/projet/CREDITS.md +41 -0
- package/cadre/templates/projet/README.md +152 -0
- package/cadre/templates/projet/_gitignore +91 -0
- package/cadre/templates/projet/_npmignore +46 -0
- package/cadre/templates/projet/deployment/README.md +98 -0
- package/cadre/templates/projet/deployment/docs/01-INSTALL.md +145 -0
- package/cadre/templates/projet/deployment/docs/02-CONFIGURATION.md +117 -0
- package/cadre/templates/projet/deployment/docs/03-API.md +264 -0
- package/cadre/templates/projet/deployment/docs/04-TROUBLESHOOTING.md +262 -0
- package/cadre/templates/projet/deployment/scripts/install.ps1 +100 -0
- package/cadre/templates/projet/deployment/scripts/start.ps1 +61 -0
- package/cadre/templates/projet/deployment/scripts/stop.ps1 +37 -0
- package/cadre/templates/projet/deployment/scripts/test.ps1 +118 -0
- package/cadre/templates/projet/docs/agents/issue-tracker.md +44 -0
- package/cadre/templates/projet/ecosystem.config.cjs +73 -0
- package/cadre/templates/projet/package.json +90 -0
- package/cadre/templates/projet/pitmaster/SUIVI.md +22 -0
- package/cadre/templates/projet/src/config.ts +68 -0
- package/cadre/templates/projet/src/errors.ts +102 -0
- package/cadre/templates/projet/src/index.ts +46 -0
- package/cadre/templates/projet/src/services/.gitkeep +8 -0
- package/cadre/templates/projet/src/types/index.ts +24 -0
- package/cadre/templates/projet/src/utils/logger.ts +106 -0
- package/cadre/templates/projet/tests/integration/.gitkeep +7 -0
- package/cadre/templates/projet/tests/unit/config.spec.ts +68 -0
- package/cadre/templates/projet/tests/unit/errors.spec.ts +132 -0
- package/cadre/templates/projet/tests/unit/types.spec.ts +73 -0
- package/cadre/templates/projet/tsconfig.eslint.json +9 -0
- package/cadre/templates/projet/tsconfig.json +41 -0
- package/cadre/templates/projet/tsdoc.json +6 -0
- package/cadre/templates/projet/vitest.config.ts +44 -0
- package/cadre/templates/turbo/paquets.json +29 -0
- package/cadre/templates/turbo/sans-paquets.json +28 -0
- package/charte.md +107 -0
- package/docs/ARCHITECTURE.md +90 -0
- package/hooks/crochet.mjs +33 -0
- package/hooks/hooks.json +58 -0
- package/hooks/register.tsx +558 -0
- package/package.json +75 -4
- package/scripts/avancement.mjs +244 -0
- package/scripts/bilan.mjs +523 -0
- package/scripts/branche-de-nuit.mjs +59 -0
- package/scripts/cadre.mjs +109 -0
- package/scripts/circuit.mjs +4375 -0
- package/scripts/code-mort.mjs +371 -0
- package/scripts/composants-affectes.mjs +598 -0
- package/scripts/consommateurs-arbitres.mjs +192 -0
- package/scripts/consommateurs.mjs +310 -0
- package/scripts/crochet.mjs +24 -0
- package/scripts/crochets.mjs +135 -0
- package/scripts/dernier-vert.mjs +208 -0
- package/scripts/dette.mjs +181 -0
- package/scripts/droits.mjs +354 -0
- package/scripts/enveloppe/codes.mjs +17 -0
- package/scripts/enveloppe/composant.mjs +11 -0
- package/scripts/enveloppe/enveloppe.mjs +628 -0
- package/scripts/enveloppe/lancer.sh +311 -0
- package/scripts/etapes.mjs +323 -0
- package/scripts/etat-du-circuit.mjs +104 -0
- package/scripts/frontieres.mjs +456 -0
- package/scripts/gardes-du-cadre.mjs +72 -0
- package/scripts/greffons.mjs +338 -0
- package/scripts/grillhouse-maj.mjs +514 -0
- package/scripts/index-interfaces.mjs +293 -0
- package/scripts/init.mjs +117 -0
- package/scripts/integration/file-attente.mjs +61 -0
- package/scripts/integration/file.mjs +494 -0
- package/scripts/integration/integrer.mjs +381 -0
- package/scripts/integration/rejeu.mjs +139 -0
- package/scripts/integration/verdict.mjs +13 -0
- package/scripts/interfaces-contre-code.mjs +547 -0
- package/scripts/ligne-etat/defaut.sh +110 -0
- package/scripts/ligne-etat/ligne-etat.mjs +93 -0
- package/scripts/migrations/0.23.0-charte-importee.mjs +47 -0
- package/scripts/migrations/0.23.0-config-vitest.mjs +105 -0
- package/scripts/migrations/0.23.0-crochets-de-seance.mjs +55 -0
- package/scripts/migrations/0.23.0-marche-du-projet.mjs +82 -0
- package/scripts/migrations.mjs +43 -0
- package/scripts/nuit.sh +269 -0
- package/scripts/paquets.mjs +79 -0
- package/scripts/poussee-cles.mjs +46 -0
- package/scripts/preparation.mjs +84 -0
- package/scripts/references-par-les-types.mjs +420 -0
- package/scripts/registre.mjs +336 -0
- package/scripts/resultats.mjs +580 -0
- package/scripts/resumes.mjs +57 -0
- package/scripts/retirer-copie.sh +127 -0
- package/scripts/session-start.sh +203 -0
- package/scripts/sortie.mjs +155 -0
- package/scripts/sous-modules.sh +316 -0
- package/scripts/structure-guard.sh +27 -0
- package/scripts/superviseur.mjs +102 -0
- package/scripts/tableau.mjs +1886 -0
- package/scripts/tests.mjs +236 -0
- package/scripts/ticket.sh +23 -0
- package/scripts/turbo-des-paquets.mjs +899 -0
- package/scripts/un-commit-par-ticket.mjs +212 -0
- package/scripts/verifier.mjs +469 -0
- package/scripts/verrou-de-fichier.mjs +130 -0
- package/scripts/verrou-de-machine.mjs +211 -0
- package/scripts/verrous/commande.mjs +180 -0
- package/scripts/verrous/ticket-du-sous-agent.mjs +39 -0
- package/scripts/verrous/verrou.mjs +165 -0
- package/scripts/vitest-config/avancement.mjs +39 -0
- package/scripts/vitest-config/avancement.reporter.mjs +56 -0
- package/scripts/vitest-config/base-de-passe.mjs +128 -0
- package/scripts/vitest-config/base.d.ts +6 -0
- package/scripts/vitest-config/base.mjs +87 -0
- package/scripts/vitest-config/changements.mjs +173 -0
- package/scripts/vitest-config/cibles.mjs +207 -0
- package/scripts/vitest-config/duree.reporter.mjs +98 -0
- package/scripts/vitest-config/machine.setup.mjs +14 -0
- package/scripts/vitest-config/mesure.d.ts +6 -0
- package/scripts/vitest-config/mesure.mjs +13 -0
- package/scripts/vitest-config/mesure.setup.mjs +12 -0
- package/scripts/vitest-config/pression.mjs +90 -0
- package/scripts/vitest-config/resultats.mjs +23 -0
- package/scripts/vitest-config/resultats.setup.mjs +19 -0
- package/scripts/vitest.nuit.config.mjs +26 -0
- package/skills/developpeur/SKILL.md +175 -0
- package/skills/explorateur/SKILL.md +84 -0
- package/skills/grill/SKILL.md +238 -0
- package/skills/grill/references/releve-structurel.md +38 -0
- package/skills/mesure/SKILL.md +168 -0
- package/skills/pitmaster/SKILL.md +382 -0
- package/skills/pitmaster/references/cadre.md +119 -0
- package/skills/pitmaster/references/consigne-agent.md +308 -0
- package/skills/pitmaster/references/erreurs.md +25 -0
- package/skills/pitmaster/references/tour.md +124 -0
- package/skills/questionneur/SKILL.md +64 -0
- package/skills/redacteur/SKILL.md +84 -0
- package/skills/redacteur/references/documents-d-un-composant.md +105 -0
- package/skills/referent-technique/SKILL.md +145 -0
- package/skills/regulateur/SKILL.md +220 -0
- package/skills/release/SKILL.md +134 -0
- package/skills/release/scripts/update-version.cjs +92 -0
- package/skills/relecteur/SKILL.md +152 -0
- package/skills/relecteur/references/LICENSE-MIT +30 -0
- package/skills/relecteur/references/SOURCE.md +8 -0
- package/skills/relecteur/references/claims-check.md +14 -0
- package/skills/relecteur/references/deletion-check.md +14 -0
- package/skills/relecteur/references/edge-case-hunter.md +80 -0
- package/skills/relecteur/references/verification-gap.md +113 -0
- package/skills/testwriter/SKILL.md +187 -0
- package/types/index.d.ts +56 -0
- package/README.md +0 -3
package/METACADRE.md
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Le métacadre de Grillhouse
|
|
2
|
+
|
|
3
|
+
Le métacadre dit ce que sert tout le cadre, et comment ses règles s'écrivent. La charte, les
|
|
4
|
+
compétences et les documents de chaque projet s'y rattachent ; une règle qui ne sert aucune de ses
|
|
5
|
+
intentions sort du cadre.
|
|
6
|
+
|
|
7
|
+
## 1. Les intentions
|
|
8
|
+
|
|
9
|
+
1. **Un produit mature et professionnel** : le projet construit une architecture robuste et
|
|
10
|
+
pérenne, qui atteint ses objectifs et tient les exigences de son domaine (la rapidité pour le
|
|
11
|
+
live coding). Il se base sur l'existant et sur ce que fait le produit mature du domaine. Les
|
|
12
|
+
cinq autres intentions servent celle-ci.
|
|
13
|
+
2. **L'architecture décide, le code suit** : chaque décision s'écrit dans l'architecture avant
|
|
14
|
+
d'être codée. Un problème remonté commence par une revue de l'architecture spécifiée : où il
|
|
15
|
+
devrait se situer ; ensuite on implémente. Ainsi le produit reste cohérent dans le temps.
|
|
16
|
+
3. **Du plus large vers le plus spécifique** : tout correctif passe par l'architecture. Un problème
|
|
17
|
+
identifié peut être la manifestation d'un problème plus large : on le traite toujours du plus
|
|
18
|
+
large vers le plus spécifique.
|
|
19
|
+
4. **La preuve avant l'affirmation** : un résultat s'affirme sur une mesure, et un test prouve
|
|
20
|
+
qu'il sait échouer avant de compter comme vert. Ainsi ce qui est déclaré fini l'est vraiment.
|
|
21
|
+
5. **Des agents cadrés** : chaque ticket part à un agent neuf, dans le cadre écrit, et un autre que
|
|
22
|
+
lui relit sa fermeture. Ainsi le travail des agents reste dans l'architecture ; sans cadre, ils
|
|
23
|
+
font systématiquement le contraire.
|
|
24
|
+
6. **Le responsable tranche l'essentiel** : ce qu'une règle écrite tranche, le régulateur ou
|
|
25
|
+
le superviseur le tranche. Le responsable reçoit les décisions qu'aucune règle ne couvre, avec leur contexte et une
|
|
26
|
+
recommandation. Ainsi son temps va aux vraies décisions.
|
|
27
|
+
|
|
28
|
+
## 2. Écrire une règle
|
|
29
|
+
|
|
30
|
+
**Écrire une règle** : une règle part des mots de celui qui l'a décidée. Elle dit en positif ce
|
|
31
|
+
qu'on fait, au présent, en deux ou trois phrases courtes. Elle nomme l'intention du cadre qu'elle
|
|
32
|
+
sert, pour qu'on ne puisse pas l'appliquer contre elle. Elle nomme les objets qu'elle cadre, à leur
|
|
33
|
+
échelle ; un exemple l'éclaire, jamais une liste de cas.
|
|
34
|
+
|
|
35
|
+
**Une règle, une idée** : une règle dit une seule chose, qu'un lecteur comprend sans connaître son
|
|
36
|
+
origine. Deux idées font deux règles ; une idée déjà écrite ailleurs se cite à son adresse. Ainsi
|
|
37
|
+
un agent applique chaque règle sans la mal lire.
|
|
38
|
+
|
|
39
|
+
Exemple : « Avant le code, tu nommes dans le ticket la règle du cadre et la règle d'architecture
|
|
40
|
+
que tu appliques. Ainsi le code suit l'architecture ; quand aucune règle ne s'applique, la décision
|
|
41
|
+
manque et remonte au superviseur. »
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: developpeur
|
|
3
|
+
model: sonnet
|
|
4
|
+
effort: medium
|
|
5
|
+
description: Travaille le code d'un ticket dont les tests existent. N'écrit aucun test, ni la matière de test partagée, ni de code avant la section Architecture du ticket.
|
|
6
|
+
skills:
|
|
7
|
+
- grillhouse:developpeur
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
Tu es le développeur. Au premier tour, charge ta compétence `developpeur` (outil Skill), puis suis-la : ta séance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: explorateur
|
|
3
|
+
description: "Mène un ticket d'exploration : relève l'état réel, liste les décisions à prendre, propose les tickets de réalisation. N'écrit aucun fichier."
|
|
4
|
+
skills:
|
|
5
|
+
- grillhouse:explorateur
|
|
6
|
+
disallowedTools: Write, Edit, MultiEdit, NotebookEdit
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Tu es l'explorateur. Ta compétence `explorateur` est chargée : suis-la.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: questionneur
|
|
3
|
+
description: Questionne une proposition qu'il n'a pas écrite (le plan d'un ticket, une décision du régulateur, un plan du superviseur) là où elle lui paraît floue, à la lumière du cadre ; ne décide rien, ne propose pas sa solution, n'écrit aucun fichier ni rien au ticket.
|
|
4
|
+
skills:
|
|
5
|
+
- grillhouse:questionneur
|
|
6
|
+
model: sonnet
|
|
7
|
+
effort: medium
|
|
8
|
+
disallowedTools: Write, Edit, MultiEdit, NotebookEdit
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
Tu es le questionneur. Au premier tour, charge ta compétence `questionneur` (outil Skill), puis suis-la : ta séance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: referent-technique
|
|
3
|
+
description: Tranche une question de conception née d'un ticket, ou la fait monter au responsable ; dans le circuit, répond pour le plan d'un ticket aux questions du questionneur. N'écrit aucun fichier.
|
|
4
|
+
skills:
|
|
5
|
+
- grillhouse:referent-technique
|
|
6
|
+
disallowedTools: Write, Edit, MultiEdit, NotebookEdit
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Tu es le référent technique. Au premier tour, charge ta compétence `referent-technique` (outil Skill) si elle n'est pas déjà chargée, puis suis-la : une séance que le circuit lance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: regulateur
|
|
3
|
+
description: Tranche un arrêt du circuit d'un ticket — lit son état et sa raison, tranche ce que les règles tranchent, rend sa décision dans sa fiche (RELANCE, que le circuit applique, ou MONTE, la question au superviseur). Lancé neuf par le circuit sur chaque arrêt. N'écrit ni code ni test.
|
|
4
|
+
skills:
|
|
5
|
+
- grillhouse:regulateur
|
|
6
|
+
model: sonnet
|
|
7
|
+
effort: medium
|
|
8
|
+
disallowedTools: Write, Edit, MultiEdit, NotebookEdit
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
Tu es le régulateur. Au premier tour, charge ta compétence `regulateur` (outil Skill), puis suis-la : ta séance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: relecteur
|
|
3
|
+
description: Relit en adversaire le lot d'un ticket (tests et code) et rend son verdict, que le circuit écrit au ticket. N'écrit rien dans le code.
|
|
4
|
+
skills:
|
|
5
|
+
- grillhouse:relecteur
|
|
6
|
+
disallowedTools: Write, Edit, MultiEdit, NotebookEdit
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
Tu es le relecteur. Au premier tour, charge ta compétence `relecteur` (outil Skill), puis suis-la : ta séance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: testwriter
|
|
3
|
+
model: sonnet
|
|
4
|
+
effort: medium
|
|
5
|
+
description: Écrit les tests d'un ticket depuis la spécification, avant le code. N'écrit que des fichiers de test et la matière de test partagée.
|
|
6
|
+
skills:
|
|
7
|
+
- grillhouse:testwriter
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
Tu es le testwriter. Au premier tour, charge ta compétence `testwriter` (outil Skill), puis suis-la : ta séance ne la reçoit pas chargée.
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// The frame's one command: `grillhouse <sous-commande> [arguments…]`, as `turbo run` or
|
|
3
|
+
// `changeset version` are one executable with subcommands. A project calls `npx grillhouse
|
|
4
|
+
// <sous-commande>` (`grillhouse <sous-commande>` in its npm scripts), never a path of the frame.
|
|
5
|
+
//
|
|
6
|
+
// - Each subcommand is a script of the package (`scripts/`), run with the arguments that follow
|
|
7
|
+
// it, in the working directory of the call, which is the project's. A `.mjs` runs in this
|
|
8
|
+
// process, as if Node had been given its path (`process.argv[1]` is the script's, the arguments
|
|
9
|
+
// after it): no second Node starts, which a hook of Claude Code called at each tool pays. A `.sh`
|
|
10
|
+
// runs by bash, its standard streams this process's, its exit code this command's, and a script
|
|
11
|
+
// ended by a signal gives 128 plus the signal's number, as a shell gives it.
|
|
12
|
+
// - A subcommand is named after its script, without directory nor extension (`verifier`,
|
|
13
|
+
// `circuit`, `tableau`); `maj` runs `grillhouse-maj.mjs`, whose name already says the frame's;
|
|
14
|
+
// `hooks` (`crochets.mjs`, which places the git hooks) and `hook` (`crochet.mjs`, which runs one)
|
|
15
|
+
// take Husky's names, which a project's `prepare` and its git hooks call.
|
|
16
|
+
// - A subcommand missing or unknown writes the usage and the list of the subcommands on the error
|
|
17
|
+
// stream, and the exit code is 2.
|
|
18
|
+
// - A script finds its neighbours by its own directory, and the project by the working directory
|
|
19
|
+
// (`CLAUDE_PROJECT_DIR` for a hook of Claude Code): the package works wherever it is installed.
|
|
20
|
+
import { spawn } from 'node:child_process';
|
|
21
|
+
import { realpathSync } from 'node:fs';
|
|
22
|
+
import { constants } from 'node:os';
|
|
23
|
+
import path from 'node:path';
|
|
24
|
+
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
25
|
+
|
|
26
|
+
const SCRIPTS = path.join(path.dirname(fileURLToPath(import.meta.url)), '..', 'scripts');
|
|
27
|
+
|
|
28
|
+
// Each subcommand and its script, under `scripts/`.
|
|
29
|
+
export const SOUS_COMMANDES = {
|
|
30
|
+
bilan: 'bilan.mjs',
|
|
31
|
+
circuit: 'circuit.mjs',
|
|
32
|
+
'code-mort': 'code-mort.mjs',
|
|
33
|
+
commande: 'verrous/commande.mjs',
|
|
34
|
+
'composants-affectes': 'composants-affectes.mjs',
|
|
35
|
+
consommateurs: 'consommateurs.mjs',
|
|
36
|
+
'consommateurs-arbitres': 'consommateurs-arbitres.mjs',
|
|
37
|
+
droits: 'droits.mjs',
|
|
38
|
+
enveloppe: 'enveloppe/enveloppe.mjs',
|
|
39
|
+
'etat-du-circuit': 'etat-du-circuit.mjs',
|
|
40
|
+
file: 'integration/file.mjs',
|
|
41
|
+
frontieres: 'frontieres.mjs',
|
|
42
|
+
'gardes-du-cadre': 'gardes-du-cadre.mjs',
|
|
43
|
+
greffons: 'greffons.mjs',
|
|
44
|
+
hook: 'crochet.mjs',
|
|
45
|
+
hooks: 'crochets.mjs',
|
|
46
|
+
'index-interfaces': 'index-interfaces.mjs',
|
|
47
|
+
init: 'init.mjs',
|
|
48
|
+
integrer: 'integration/integrer.mjs',
|
|
49
|
+
'interfaces-contre-code': 'interfaces-contre-code.mjs',
|
|
50
|
+
lancer: 'enveloppe/lancer.sh',
|
|
51
|
+
'ligne-etat': 'ligne-etat/ligne-etat.mjs',
|
|
52
|
+
maj: 'grillhouse-maj.mjs',
|
|
53
|
+
nuit: 'nuit.sh',
|
|
54
|
+
pression: 'vitest-config/pression.mjs',
|
|
55
|
+
registre: 'registre.mjs',
|
|
56
|
+
resultats: 'resultats.mjs',
|
|
57
|
+
resumes: 'resumes.mjs',
|
|
58
|
+
'retirer-copie': 'retirer-copie.sh',
|
|
59
|
+
'session-start': 'session-start.sh',
|
|
60
|
+
sortie: 'sortie.mjs',
|
|
61
|
+
'sous-modules': 'sous-modules.sh',
|
|
62
|
+
'structure-guard': 'structure-guard.sh',
|
|
63
|
+
superviseur: 'superviseur.mjs',
|
|
64
|
+
tableau: 'tableau.mjs',
|
|
65
|
+
tests: 'tests.mjs',
|
|
66
|
+
ticket: 'ticket.sh',
|
|
67
|
+
'ticket-du-sous-agent': 'verrous/ticket-du-sous-agent.mjs',
|
|
68
|
+
'turbo-des-paquets': 'turbo-des-paquets.mjs',
|
|
69
|
+
verifier: 'verifier.mjs',
|
|
70
|
+
verrou: 'verrous/verrou.mjs',
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
// The absolute path of the script of the subcommand <nom>; null for a name the table lacks.
|
|
74
|
+
export function scriptDe(nom) {
|
|
75
|
+
return Object.hasOwn(SOUS_COMMANDES, nom) ? path.join(SCRIPTS, SOUS_COMMANDES[nom]) : null;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// The usage and the list of the subcommands, as the error stream receives them.
|
|
79
|
+
const usage = () =>
|
|
80
|
+
'Usage : grillhouse <sous-commande> [arguments…]\n' +
|
|
81
|
+
`Sous-commandes : ${Object.keys(SOUS_COMMANDES).join(', ')}\n`;
|
|
82
|
+
|
|
83
|
+
// The command is run by its link (`node_modules/.bin/grillhouse`), which Node resolves for the
|
|
84
|
+
// module, not for `process.argv[1]`.
|
|
85
|
+
const lance = () => {
|
|
86
|
+
try {
|
|
87
|
+
return pathToFileURL(realpathSync(process.argv[1] ?? '')).href;
|
|
88
|
+
} catch {
|
|
89
|
+
return null;
|
|
90
|
+
}
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
// The script of the subcommand, run (see the header); the exit code is set, never forced
|
|
94
|
+
// (`process.exitCode`), so that what the command wrote on a pipe reaches its reader.
|
|
95
|
+
async function lancer([nom, ...args]) {
|
|
96
|
+
const script = nom === undefined ? null : scriptDe(nom);
|
|
97
|
+
if (script === null) {
|
|
98
|
+
process.stderr.write(
|
|
99
|
+
nom === undefined ? usage() : `⛔ sous-commande inconnue : ${nom}\n${usage()}`
|
|
100
|
+
);
|
|
101
|
+
process.exitCode = 2;
|
|
102
|
+
return;
|
|
103
|
+
}
|
|
104
|
+
if (script.endsWith('.mjs')) {
|
|
105
|
+
process.argv = [process.argv[0], script, ...args];
|
|
106
|
+
await import(pathToFileURL(script).href);
|
|
107
|
+
return;
|
|
108
|
+
}
|
|
109
|
+
const enfant = spawn('bash', [script, ...args], { stdio: 'inherit' });
|
|
110
|
+
// A signal this process receives goes to the script, which decides how it ends.
|
|
111
|
+
const relais = s => enfant.kill(s);
|
|
112
|
+
for (const s of ['SIGINT', 'SIGTERM', 'SIGHUP']) process.on(s, relais);
|
|
113
|
+
enfant.on('error', e => {
|
|
114
|
+
process.stderr.write(`⛔ grillhouse ${nom} : ${e.message}\n`);
|
|
115
|
+
process.exitCode = 1;
|
|
116
|
+
});
|
|
117
|
+
enfant.on('exit', (code, signal) => {
|
|
118
|
+
process.exitCode = code ?? 128 + (constants.signals[signal] ?? 0);
|
|
119
|
+
for (const s of ['SIGINT', 'SIGTERM', 'SIGHUP']) process.off(s, relais);
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
if (import.meta.url === lance()) {
|
|
124
|
+
await lancer(process.argv.slice(2));
|
|
125
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/anthropics/claude-code/main/schemas/settings.schema.json",
|
|
3
|
+
"permissions": {
|
|
4
|
+
"allow": [
|
|
5
|
+
"Bash(npm run *)",
|
|
6
|
+
"Bash(npm test*)",
|
|
7
|
+
"Bash(npm install*)",
|
|
8
|
+
"Bash(git *)",
|
|
9
|
+
"Bash(gh *)",
|
|
10
|
+
"Bash(bd *)",
|
|
11
|
+
"mcp__codegraph__*",
|
|
12
|
+
"mcp__plugin_rtfm_rtfm__*"
|
|
13
|
+
],
|
|
14
|
+
"deny": []
|
|
15
|
+
},
|
|
16
|
+
"enabledPlugins": {
|
|
17
|
+
"mattpocock-skills@claude-plugins-official": true,
|
|
18
|
+
"rtfm@roomi-fields": true,
|
|
19
|
+
"grillhouse@roomi-fields": true
|
|
20
|
+
},
|
|
21
|
+
"extraKnownMarketplaces": {
|
|
22
|
+
"roomi-fields": {
|
|
23
|
+
"source": {
|
|
24
|
+
"source": "github",
|
|
25
|
+
"repo": "roomi-fields/claude-plugins"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"enabledMcpjsonServers": ["codegraph"]
|
|
30
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# EditorConfig helps maintain consistent coding styles across different editors
|
|
2
|
+
# https://editorconfig.org
|
|
3
|
+
|
|
4
|
+
root = true
|
|
5
|
+
|
|
6
|
+
# Default settings for all files
|
|
7
|
+
[*]
|
|
8
|
+
charset = utf-8
|
|
9
|
+
end_of_line = lf
|
|
10
|
+
indent_style = space
|
|
11
|
+
indent_size = 2
|
|
12
|
+
insert_final_newline = true
|
|
13
|
+
trim_trailing_whitespace = true
|
|
14
|
+
|
|
15
|
+
# TypeScript/JavaScript files
|
|
16
|
+
[*.{ts,tsx,js,jsx,mjs,cjs}]
|
|
17
|
+
indent_size = 2
|
|
18
|
+
|
|
19
|
+
# JSON files
|
|
20
|
+
[*.json]
|
|
21
|
+
indent_size = 2
|
|
22
|
+
|
|
23
|
+
# YAML files
|
|
24
|
+
[*.{yml,yaml}]
|
|
25
|
+
indent_size = 2
|
|
26
|
+
|
|
27
|
+
# Markdown files
|
|
28
|
+
[*.md]
|
|
29
|
+
trim_trailing_whitespace = false
|
|
30
|
+
max_line_length = off
|
|
31
|
+
|
|
32
|
+
# Shell scripts
|
|
33
|
+
[*.{sh,bash}]
|
|
34
|
+
indent_size = 2
|
|
35
|
+
|
|
36
|
+
# PowerShell scripts
|
|
37
|
+
[*.{ps1,psm1,psd1}]
|
|
38
|
+
indent_size = 4
|
|
39
|
+
end_of_line = crlf
|
|
40
|
+
|
|
41
|
+
# Makefiles
|
|
42
|
+
[Makefile]
|
|
43
|
+
indent_style = tab
|
|
44
|
+
|
|
45
|
+
# Git configuration
|
|
46
|
+
[.git*]
|
|
47
|
+
indent_size = 4
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# =============================================================================
|
|
2
|
+
# Environment Configuration Template
|
|
3
|
+
# =============================================================================
|
|
4
|
+
# Copy this file to .env and fill in your values
|
|
5
|
+
# NEVER commit .env to version control
|
|
6
|
+
# =============================================================================
|
|
7
|
+
|
|
8
|
+
# -----------------------------------------------------------------------------
|
|
9
|
+
# Application Settings
|
|
10
|
+
# -----------------------------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
# Environment mode (development, production, test)
|
|
13
|
+
NODE_ENV=development
|
|
14
|
+
|
|
15
|
+
# Server port
|
|
16
|
+
PORT=3000
|
|
17
|
+
|
|
18
|
+
# Log level (debug, info, warn, error)
|
|
19
|
+
LOG_LEVEL=info
|
|
20
|
+
|
|
21
|
+
# -----------------------------------------------------------------------------
|
|
22
|
+
# API Keys & Secrets
|
|
23
|
+
# -----------------------------------------------------------------------------
|
|
24
|
+
|
|
25
|
+
# Example API key (replace with your actual keys)
|
|
26
|
+
# API_KEY=your_api_key_here
|
|
27
|
+
|
|
28
|
+
# Example secret (use strong random values in production)
|
|
29
|
+
# SECRET_KEY=your_secret_key_here
|
|
30
|
+
|
|
31
|
+
# -----------------------------------------------------------------------------
|
|
32
|
+
# Database Configuration
|
|
33
|
+
# -----------------------------------------------------------------------------
|
|
34
|
+
|
|
35
|
+
# Database URL
|
|
36
|
+
# DATABASE_URL=postgresql://user:password@localhost:5432/dbname
|
|
37
|
+
|
|
38
|
+
# Redis URL
|
|
39
|
+
# REDIS_URL=redis://localhost:6379
|
|
40
|
+
|
|
41
|
+
# -----------------------------------------------------------------------------
|
|
42
|
+
# External Services
|
|
43
|
+
# -----------------------------------------------------------------------------
|
|
44
|
+
|
|
45
|
+
# Example third-party service configuration
|
|
46
|
+
# SERVICE_API_URL=https://api.example.com
|
|
47
|
+
# SERVICE_API_KEY=your_service_key
|
|
48
|
+
|
|
49
|
+
# -----------------------------------------------------------------------------
|
|
50
|
+
# Feature Flags
|
|
51
|
+
# -----------------------------------------------------------------------------
|
|
52
|
+
|
|
53
|
+
# Enable debug mode
|
|
54
|
+
# DEBUG=false
|
|
55
|
+
|
|
56
|
+
# Enable feature X
|
|
57
|
+
# FEATURE_X_ENABLED=false
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
// Shared rules hold for TypeScript and JavaScript alike; the TypeScript
|
|
2
|
+
// parser and its type-aware rules apply to .ts files only.
|
|
3
|
+
const sharedRules = {
|
|
4
|
+
'no-console': ['warn', { allow: ['warn', 'error'] }],
|
|
5
|
+
'prefer-const': 'error',
|
|
6
|
+
'no-var': 'error',
|
|
7
|
+
eqeqeq: ['error', 'always'],
|
|
8
|
+
curly: ['error', 'all'],
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
module.exports = {
|
|
12
|
+
root: true,
|
|
13
|
+
env: {
|
|
14
|
+
node: true,
|
|
15
|
+
es2022: true,
|
|
16
|
+
},
|
|
17
|
+
parserOptions: {
|
|
18
|
+
ecmaVersion: 2022,
|
|
19
|
+
sourceType: 'module',
|
|
20
|
+
},
|
|
21
|
+
extends: ['eslint:recommended'],
|
|
22
|
+
rules: {
|
|
23
|
+
...sharedRules,
|
|
24
|
+
'no-unused-vars': ['error', { argsIgnorePattern: '^_', varsIgnorePattern: '^_' }],
|
|
25
|
+
},
|
|
26
|
+
overrides: [
|
|
27
|
+
{
|
|
28
|
+
files: ['*.ts', '*.tsx'],
|
|
29
|
+
parser: '@typescript-eslint/parser',
|
|
30
|
+
parserOptions: {
|
|
31
|
+
project: './tsconfig.eslint.json',
|
|
32
|
+
},
|
|
33
|
+
plugins: ['@typescript-eslint'],
|
|
34
|
+
extends: [
|
|
35
|
+
'eslint:recommended',
|
|
36
|
+
'plugin:@typescript-eslint/recommended',
|
|
37
|
+
'plugin:@typescript-eslint/recommended-requiring-type-checking',
|
|
38
|
+
],
|
|
39
|
+
rules: {
|
|
40
|
+
...sharedRules,
|
|
41
|
+
'no-unused-vars': 'off',
|
|
42
|
+
'@typescript-eslint/explicit-function-return-type': 'off',
|
|
43
|
+
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
|
44
|
+
'@typescript-eslint/no-explicit-any': 'warn',
|
|
45
|
+
'@typescript-eslint/no-unused-vars': [
|
|
46
|
+
'error',
|
|
47
|
+
{ argsIgnorePattern: '^_', varsIgnorePattern: '^_' },
|
|
48
|
+
],
|
|
49
|
+
'@typescript-eslint/no-floating-promises': 'error',
|
|
50
|
+
'@typescript-eslint/await-thenable': 'error',
|
|
51
|
+
'@typescript-eslint/no-misused-promises': 'error',
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
],
|
|
55
|
+
ignorePatterns: ['dist/', 'node_modules/', 'coverage/', '*.cjs'],
|
|
56
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
name: CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main, develop]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main, develop]
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
test:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
strategy:
|
|
14
|
+
matrix:
|
|
15
|
+
node-version: [22.x, 24.x]
|
|
16
|
+
|
|
17
|
+
steps:
|
|
18
|
+
- name: Checkout
|
|
19
|
+
uses: actions/checkout@v5
|
|
20
|
+
|
|
21
|
+
- name: Setup Node.js ${{ matrix.node-version }}
|
|
22
|
+
uses: actions/setup-node@v5
|
|
23
|
+
with:
|
|
24
|
+
node-version: ${{ matrix.node-version }}
|
|
25
|
+
cache: 'npm'
|
|
26
|
+
|
|
27
|
+
- name: Install dependencies
|
|
28
|
+
run: npm ci
|
|
29
|
+
|
|
30
|
+
- name: Check formatting
|
|
31
|
+
run: npm run format:check
|
|
32
|
+
|
|
33
|
+
- name: Lint
|
|
34
|
+
run: npm run lint
|
|
35
|
+
|
|
36
|
+
- name: Typecheck
|
|
37
|
+
run: npm run typecheck
|
|
38
|
+
|
|
39
|
+
- name: Build
|
|
40
|
+
run: npm run build --if-present
|
|
41
|
+
|
|
42
|
+
- name: Guards and tests
|
|
43
|
+
run: npm run verifier
|
|
44
|
+
|
|
45
|
+
build:
|
|
46
|
+
runs-on: ubuntu-latest
|
|
47
|
+
needs: test
|
|
48
|
+
|
|
49
|
+
steps:
|
|
50
|
+
- name: Checkout
|
|
51
|
+
uses: actions/checkout@v5
|
|
52
|
+
|
|
53
|
+
- name: Setup Node.js
|
|
54
|
+
uses: actions/setup-node@v5
|
|
55
|
+
with:
|
|
56
|
+
node-version: '22'
|
|
57
|
+
cache: 'npm'
|
|
58
|
+
|
|
59
|
+
- name: Install dependencies
|
|
60
|
+
run: npm ci
|
|
61
|
+
|
|
62
|
+
- name: Build
|
|
63
|
+
run: npm run build --if-present
|
|
64
|
+
|
|
65
|
+
- name: Check package
|
|
66
|
+
run: npm pack --dry-run
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- (Add new features here)
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
- (Add changes to existing functionality here)
|
|
15
|
+
|
|
16
|
+
### Deprecated
|
|
17
|
+
- (Add soon-to-be removed features here)
|
|
18
|
+
|
|
19
|
+
### Removed
|
|
20
|
+
- (Add removed features here)
|
|
21
|
+
|
|
22
|
+
### Fixed
|
|
23
|
+
- (Add bug fixes here)
|
|
24
|
+
|
|
25
|
+
### Security
|
|
26
|
+
- (Add security fixes here)
|
|
27
|
+
|
|
28
|
+
## [1.0.0] - YYYY-MM-DD
|
|
29
|
+
|
|
30
|
+
### Added
|
|
31
|
+
- Initial release
|
|
32
|
+
- Core functionality
|
|
33
|
+
- Documentation
|
|
34
|
+
- CI/CD pipeline
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## Versioning Guide
|
|
39
|
+
|
|
40
|
+
### Version Format: MAJOR.MINOR.PATCH
|
|
41
|
+
|
|
42
|
+
- **MAJOR**: Incompatible API changes
|
|
43
|
+
- **MINOR**: New functionality (backward compatible)
|
|
44
|
+
- **PATCH**: Bug fixes (backward compatible)
|
|
45
|
+
|
|
46
|
+
### Commit Message Prefixes
|
|
47
|
+
|
|
48
|
+
| Prefix | Description | Version Impact |
|
|
49
|
+
|--------|-------------|----------------|
|
|
50
|
+
| `feat:` | New feature | MINOR |
|
|
51
|
+
| `fix:` | Bug fix | PATCH |
|
|
52
|
+
| `docs:` | Documentation | PATCH |
|
|
53
|
+
| `style:` | Code style | PATCH |
|
|
54
|
+
| `refactor:` | Code refactoring | PATCH |
|
|
55
|
+
| `perf:` | Performance | PATCH |
|
|
56
|
+
| `test:` | Tests | PATCH |
|
|
57
|
+
| `chore:` | Maintenance | PATCH |
|
|
58
|
+
| `BREAKING CHANGE:` | Breaking change | MAJOR |
|
|
59
|
+
|
|
60
|
+
[Unreleased]: https://github.com/your-username/project-name/compare/v1.0.0...HEAD
|
|
61
|
+
[1.0.0]: https://github.com/your-username/project-name/releases/tag/v1.0.0
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# <Nom du projet>
|
|
2
|
+
|
|
3
|
+
<Ce qu'est le projet et ce qu'il fait, en deux ou trois phrases.>
|
|
4
|
+
|
|
5
|
+
**Responsable** : <nom>. Il valide <la spécification, les ARCHITECTURE.md, les CADRE.md, les
|
|
6
|
+
INTERFACE.md> ; le superviseur valide les autres documents. Ainsi le responsable tranche
|
|
7
|
+
l'essentiel.
|
|
8
|
+
|
|
9
|
+
Les règles du cadre : @node_modules/@roomi-fields/grillhouse/charte.md
|
|
10
|
+
|
|
11
|
+
## Ce qui décide
|
|
12
|
+
|
|
13
|
+
Le métacadre (`node_modules/@roomi-fields/grillhouse/METACADRE.md` : les intentions du cadre et
|
|
14
|
+
l'écriture des règles), puis
|
|
15
|
+
<la spécification ou la cible>, puis le cadre de chaque composant (`docs/CADRE.md`,
|
|
16
|
+
`docs/INTERFACE.md`, `docs/ARCHITECTURE.md`), puis le code. Ainsi l'architecture décide, et le
|
|
17
|
+
code suit.
|
|
18
|
+
|
|
19
|
+
## Comment on arbitre
|
|
20
|
+
|
|
21
|
+
Dans cet ordre ; le projet ajoute ses propres forces à la liste, à leur rang (« le temps
|
|
22
|
+
d'abord », « une personne maintient le projet »…).
|
|
23
|
+
|
|
24
|
+
1. **Que fait la référence mature ?** <Les références du domaine : un compilateur mature, une
|
|
25
|
+
station audionumérique professionnelle…> Ce qu'elles font est la réponse par défaut ; un écart
|
|
26
|
+
porte sa raison écrite.
|
|
27
|
+
2. **Qu'est-ce qui existe déjà ?** Un standard, un outil sur étagère, une bibliothèque éprouvée,
|
|
28
|
+
une convention des projets voisins se reprend tel quel.
|
|
29
|
+
3. **Le domaine l'exige-t-il ?** <Les exigences du domaine : la rapidité pour le live coding…> Un
|
|
30
|
+
choix qui les dégrade se mesure et se dit.
|
|
31
|
+
|
|
32
|
+
## Ce qui monte au superviseur
|
|
33
|
+
|
|
34
|
+
Le fonctionnel que le régulateur ne tranche jamais seul : <le langage, le moteur audio, une
|
|
35
|
+
interface publiée…>. Le cadre et l'architecture montent toujours (charte commune).
|
|
36
|
+
|
|
37
|
+
## Commandes
|
|
38
|
+
|
|
39
|
+
- `npm test` (Turborepo : construction, puis tests ; une tâche dont rien n'a bougé est relue de son cache, `npm run test:forcer` rejoue) · `npm test -- <chemins>` (un lancement ciblé : chaque chemin écrit depuis la racine, joué dans son paquet, avec les constructions dont ses tests dépendent, relues du cache ; ses tests rejouent dès que bouge ce qu'ils importent ; un lancement qui ne joue aucun test échoue ; un banc de temps ou un test de nuit se joue quand son propre fichier est nommé, au repos) · `npm run verifier` (après la construction, les gardes du cadre, celles du projet — son script `gardes` — et les tests, côte à côte, puis les témoins de temps seuls, sous le verrou de la machine : ce que jouent l'intégration, la file, la CI et la nuit ; mesuré contre le dernier vert, un paquet rejoué joue les tests que Vitest relie aux fichiers changés depuis, tous quand un changement sort de son graphe ; 0 vert, 1 rouge, 75 « à repasser ») · `npm run verifier -- --tout` (la passe complète, chaque test joué pour de vrai : ce que joue la nuit) · `npm run verifier -- --gardes` (les gardes seules, même verdict : ce que joue le relecteur) · `npm run typecheck` · `npm run lint` · `npm run format:check`.
|
|
40
|
+
- Préfixe des tickets : `<prefixe>-`.
|
|
41
|
+
- La politique de poussée : la clé `grillhouse.poussee` du `package.json` (`commit` : la branche où
|
|
42
|
+
part chaque commit, main par défaut ; `nuit` : la branche où la nuit pousse son commit vert ;
|
|
43
|
+
seule la nuit la pousse, le crochet pre-push refuse toute autre poussée vers elle).
|
|
44
|
+
- Les sous-modules partagés : la clé `grillhouse.partage` du `package.json` (les chemins des
|
|
45
|
+
sous-modules qu'aucun ticket n'écrit ; chaque copie les lit dans le dépôt principal, en lecture
|
|
46
|
+
seule, au lieu d'en recevoir un exemplaire).
|