@roomi-fields/grillhouse 0.54.0 → 0.55.1
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 +1 -1
- package/CHANGELOG.md +75 -0
- package/cadre/templates/projet/.github/workflows/ci.yml +4 -2
- package/cadre/templates/projet/.github/workflows/machine-vierge.yml +5 -42
- package/cadre/templates/projet/CONTRIBUTING.md +0 -5
- package/cadre/templates/projet/README.md +0 -126
- package/cadre/templates/projet/_npmignore +1 -6
- package/cadre/templates/projet/package.json +5 -32
- package/cadre/templates/projet/tsconfig.json +4 -4
- package/cadre/templates/projet/vitest.config.cjs +3 -2
- package/charte/tests.md +14 -0
- package/dist/machine/part-par-sorte.d.ts +9 -9
- package/dist/machine/part-par-sorte.js +20 -24
- package/dist/machine/part-par-sorte.js.map +1 -1
- package/dist/machine/table-des-consommations.d.ts +65 -0
- package/dist/machine/table-des-consommations.js +94 -0
- package/dist/machine/table-des-consommations.js.map +1 -0
- package/dist/temporal/circuit/activites.d.ts +2 -0
- package/dist/temporal/circuit/activites.js +87 -3
- package/dist/temporal/circuit/activites.js.map +1 -1
- package/dist/temporal/circuit/client.js +9 -4
- package/dist/temporal/circuit/client.js.map +1 -1
- package/dist/temporal/circuit/contrat.d.ts +32 -4
- package/dist/temporal/circuit/deroule.js +54 -4
- package/dist/temporal/circuit/deroule.js.map +1 -1
- package/dist/temporal/circuit/versions.d.ts +12 -0
- package/dist/temporal/circuit/versions.js +22 -0
- package/dist/temporal/circuit/versions.js.map +1 -0
- package/dist/temporal/consommation/activites.d.ts +2 -0
- package/dist/temporal/consommation/activites.js +9 -0
- package/dist/temporal/consommation/activites.js.map +1 -0
- package/dist/temporal/consommation/actualisation.d.ts +2 -0
- package/dist/temporal/consommation/actualisation.js +71 -0
- package/dist/temporal/consommation/actualisation.js.map +1 -0
- package/dist/temporal/consommation/client.d.ts +12 -0
- package/dist/temporal/consommation/client.js +28 -0
- package/dist/temporal/consommation/client.js.map +1 -0
- package/dist/temporal/consommation/commande.d.ts +5 -0
- package/dist/temporal/consommation/commande.js +32 -0
- package/dist/temporal/consommation/commande.js.map +1 -0
- package/dist/temporal/consommation/contrat.d.ts +15 -0
- package/dist/temporal/consommation/contrat.js +13 -0
- package/dist/temporal/consommation/contrat.js.map +1 -0
- package/dist/temporal/consommation/deroule.d.ts +2 -0
- package/dist/temporal/consommation/deroule.js +14 -0
- package/dist/temporal/consommation/deroule.js.map +1 -0
- package/dist/temporal/deroules.d.ts +2 -1
- package/dist/temporal/deroules.js +3 -2
- package/dist/temporal/deroules.js.map +1 -1
- package/dist/temporal/file/contrat.d.ts +2 -0
- package/dist/temporal/file/deroule.js +14 -4
- package/dist/temporal/file/deroule.js.map +1 -1
- package/dist/temporal/installation.d.ts +6 -0
- package/dist/temporal/installation.js +15 -0
- package/dist/temporal/installation.js.map +1 -1
- package/dist/temporal/nuits/activites.d.ts +2 -1
- package/dist/temporal/nuits/activites.js +127 -3
- package/dist/temporal/nuits/activites.js.map +1 -1
- package/dist/temporal/nuits/client.d.ts +19 -5
- package/dist/temporal/nuits/client.js +33 -23
- package/dist/temporal/nuits/client.js.map +1 -1
- package/dist/temporal/nuits/commande.js +16 -11
- package/dist/temporal/nuits/commande.js.map +1 -1
- package/dist/temporal/nuits/contrat.d.ts +29 -0
- package/dist/temporal/nuits/contrat.js +10 -0
- package/dist/temporal/nuits/contrat.js.map +1 -1
- package/dist/temporal/nuits/deroule.d.ts +5 -0
- package/dist/temporal/nuits/deroule.js +18 -1
- package/dist/temporal/nuits/deroule.js.map +1 -1
- package/dist/temporal/nuits/pc2.d.ts +72 -0
- package/dist/temporal/nuits/pc2.js +206 -0
- package/dist/temporal/nuits/pc2.js.map +1 -0
- package/dist/temporal/places/activites.d.ts +23 -1
- package/dist/temporal/places/activites.js +38 -2
- package/dist/temporal/places/activites.js.map +1 -1
- package/dist/temporal/places/client.d.ts +16 -0
- package/dist/temporal/places/client.js +25 -1
- package/dist/temporal/places/client.js.map +1 -1
- package/dist/temporal/places/contrat.d.ts +79 -14
- package/dist/temporal/places/contrat.js +7 -0
- package/dist/temporal/places/contrat.js.map +1 -1
- package/dist/temporal/places/deroule.js +159 -23
- package/dist/temporal/places/deroule.js.map +1 -1
- package/dist/temporal/places/reservation.d.ts +54 -0
- package/dist/temporal/places/reservation.js +69 -0
- package/dist/temporal/places/reservation.js.map +1 -0
- package/dist/temporal/planification.d.ts +6 -0
- package/dist/temporal/planification.js +26 -0
- package/dist/temporal/planification.js.map +1 -0
- package/dist/temporal/tickets/activites.d.ts +0 -2
- package/dist/temporal/tickets/activites.js +2 -52
- package/dist/temporal/tickets/activites.js.map +1 -1
- package/dist/temporal/tickets/contrat.d.ts +7 -26
- package/dist/temporal/tickets/deroule.js +35 -23
- package/dist/temporal/tickets/deroule.js.map +1 -1
- package/dist/temporal/travailleur.js +2 -0
- package/dist/temporal/travailleur.js.map +1 -1
- package/docs/ARCHITECTURE.md +2 -2
- package/docs/CADRE.md +1 -1
- package/docs/INTERFACE.md +16 -11
- package/docs/architecture/circuit.md +62 -58
- package/docs/architecture/entree.md +87 -63
- package/docs/architecture/greffon.md +32 -27
- package/docs/architecture/installation.md +43 -32
- package/docs/architecture/machine.md +48 -40
- package/docs/architecture/tests.md +37 -33
- package/docs/lexique.md +4 -3
- package/package.json +1 -1
- package/scripts/activites.mjs +351 -180
- package/scripts/aiguillage.mjs +1 -0
- package/scripts/attente-de-la-machine.mjs +3 -22
- package/scripts/avancement.mjs +21 -30
- package/scripts/bilan.mjs +22 -2
- package/scripts/branche-de-nuit.mjs +1 -1
- package/scripts/circuit.mjs +75 -39
- package/scripts/codes-de-sortie.mjs +0 -6
- package/scripts/consommation-des-passes.mjs +67 -31
- package/scripts/consommation.mjs +152 -24
- package/scripts/copies-finies.mjs +15 -35
- package/scripts/dernier-vert.mjs +4 -5
- package/scripts/dette.mjs +5 -3
- package/scripts/droits.mjs +2 -2
- package/scripts/echantillonneur-de-la-passe.mjs +7 -31
- package/scripts/engendres.mjs +5 -61
- package/scripts/enveloppe/enveloppe.mjs +30 -34
- package/scripts/enveloppe/travail-de-la-copie.mjs +5 -0
- package/scripts/etapes.mjs +21 -7
- package/scripts/etat-du-depot.mjs +61 -0
- package/scripts/faits-du-circuit.mjs +7 -4
- package/scripts/fermeture-de-la-machine.d.mts +6 -4
- package/scripts/fermeture-de-la-machine.mjs +12 -16
- package/scripts/fichier-du-poste.d.mts +9 -0
- package/scripts/file-des-tickets.d.mts +0 -18
- package/scripts/file-des-tickets.mjs +0 -42
- package/scripts/fusion-du-changelog.mjs +1 -1
- package/scripts/greffons.mjs +282 -17
- package/scripts/grillhouse-maj.mjs +1 -1
- package/scripts/index-des-rouges.d.mts +40 -0
- package/scripts/index-des-rouges.mjs +104 -0
- package/scripts/integration/file.mjs +13 -63
- package/scripts/integration/integrer.mjs +157 -424
- package/scripts/integration/jugement.mjs +109 -0
- package/scripts/integration/rejeu.mjs +94 -71
- package/scripts/jointure.d.ts +34 -27
- package/scripts/journal-des-etats.d.mts +1 -1
- package/scripts/langages/c/commandes.mjs +27 -12
- package/scripts/langages/cargo/commandes.mjs +148 -94
- package/scripts/langages/cargo/index.mjs +2 -1
- package/scripts/langages/cargo/lectures-des-tests.mjs +132 -0
- package/scripts/langages/cargo/migrations/lectures-des-tests.mjs +31 -0
- package/scripts/langages/python/commandes.mjs +31 -15
- package/scripts/langages/python/index.mjs +2 -1
- package/scripts/langages/python/lectures-des-tests.mjs +148 -0
- package/scripts/langages/python/migrations/lectures-des-tests.mjs +31 -0
- package/scripts/langages/typescript/consommateurs-arbitres.mjs +2 -2
- package/scripts/langages/typescript/index.mjs +4 -0
- package/scripts/langages/typescript/lectures-des-tests.mjs +95 -0
- package/scripts/langages/typescript/migrations/lectures-des-tests.mjs +31 -0
- package/scripts/langages/typescript/tests-de-nuit.mjs +9 -15
- package/scripts/langages/typescript/tests.mjs +11 -37
- package/scripts/langages/typescript/titres-de-tests.mjs +5 -4
- package/scripts/langages/typescript/verifier.mjs +74 -44
- package/scripts/langages/typescript/vitest-config/base.mjs +3 -3
- package/scripts/langages/typescript/vitest-config/machine.setup.mjs +6 -25
- package/scripts/lectures-communes.mjs +234 -0
- package/scripts/machine.mjs +11 -18
- package/scripts/mesure/base-de-passe.mjs +1 -2
- package/scripts/mesure-de-la-machine.d.mts +40 -3
- package/scripts/mesure-de-la-machine.mjs +201 -11
- package/scripts/migrations/0.33.0-ci-du-cadre.mjs +3 -3
- package/scripts/migrations/nuit-yml-retire.mjs +25 -0
- package/scripts/migrations/part-retiree.mjs +31 -0
- package/scripts/migrations.mjs +4 -0
- package/scripts/montee.mjs +22 -1
- package/scripts/nuit-de-pc2.mjs +628 -0
- package/scripts/nuit.sh +8 -131
- package/scripts/paquets.mjs +1 -1
- package/scripts/passe-de-la-machine.mjs +340 -103
- package/scripts/place-du-circuit.d.mts +15 -0
- package/scripts/place-du-circuit.mjs +32 -0
- package/scripts/places-de-la-machine.mjs +148 -626
- package/scripts/places-du-serveur.mjs +26 -13
- package/scripts/plafond-de-la-machine.d.mts +8 -13
- package/scripts/plafond-de-la-machine.mjs +26 -56
- package/scripts/registre-des-entrees.mjs +57 -0
- package/scripts/regles-des-places.d.mts +82 -50
- package/scripts/regles-des-places.mjs +192 -156
- package/scripts/retirer-copie.sh +9 -2
- package/scripts/seances.mjs +181 -63
- package/scripts/secours.mjs +95 -0
- package/scripts/services-du-noyau.mjs +11 -19
- package/scripts/sous-commandes.mjs +1 -0
- package/scripts/sous-modules.sh +1 -1
- package/scripts/superviseur.mjs +98 -20
- package/scripts/table-des-consommations.d.mts +9 -0
- package/scripts/table-des-consommations.mjs +35 -0
- package/scripts/tableau.mjs +33 -19
- package/scripts/taches-du-graphe.mjs +124 -2
- package/scripts/transitions.d.mts +27 -5
- package/scripts/transitions.mjs +122 -104
- package/scripts/verdict-de-la-nuit.d.mts +13 -0
- package/scripts/verdict-de-la-nuit.mjs +34 -7
- package/scripts/verrou-de-fichier.mjs +1 -2
- package/scripts/workflows-du-cadre.mjs +2 -2
- package/skills/developpeur/SKILL.md +8 -2
- package/skills/direct/SKILL.md +5 -0
- package/skills/explorateur/SKILL.md +10 -1
- package/skills/grill/SKILL.md +2 -4
- package/skills/pitmaster/SKILL.md +14 -7
- package/skills/pitmaster/references/consigne-agent.md +1 -1
- package/skills/relecteur/SKILL.md +4 -1
- package/skills/testwriter/SKILL.md +15 -2
- package/cadre/templates/projet/.env.example +0 -57
- package/cadre/templates/projet/.github/workflows/nuit.yml +0 -139
- package/cadre/templates/projet/deployment/README.md +0 -98
- package/cadre/templates/projet/deployment/docs/01-INSTALL.md +0 -145
- package/cadre/templates/projet/deployment/docs/02-CONFIGURATION.md +0 -117
- package/cadre/templates/projet/deployment/docs/03-API.md +0 -264
- package/cadre/templates/projet/deployment/docs/04-TROUBLESHOOTING.md +0 -262
- package/cadre/templates/projet/deployment/scripts/install.ps1 +0 -100
- package/cadre/templates/projet/deployment/scripts/start.ps1 +0 -61
- package/cadre/templates/projet/deployment/scripts/stop.ps1 +0 -37
- package/cadre/templates/projet/deployment/scripts/test.ps1 +0 -118
- package/cadre/templates/projet/ecosystem.config.cjs +0 -73
- package/cadre/templates/projet/src/config.ts +0 -68
- package/cadre/templates/projet/src/errors.ts +0 -102
- package/cadre/templates/projet/src/index.ts +0 -46
- package/cadre/templates/projet/src/services/.gitkeep +0 -8
- package/cadre/templates/projet/src/types/index.ts +0 -24
- package/cadre/templates/projet/src/utils/logger.ts +0 -106
- package/cadre/templates/projet/tests/unit/config.spec.ts +0 -68
- package/cadre/templates/projet/tests/unit/errors.spec.ts +0 -132
- package/cadre/templates/projet/tests/unit/types.spec.ts +0 -73
- package/cadre/templates/projet/tsconfig.build.json +0 -14
- package/scripts/flux-de-la-nuit.mjs +0 -39
- package/scripts/garde-de-la-memoire.mjs +0 -231
- package/scripts/repli-de-la-nuit.mjs +0 -184
package/scripts/nuit.sh
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
2
|
# The night pass (packages/grillhouse/docs/architecture/entree.md §3.1 « Passe de nuit », §5.3):
|
|
3
3
|
# once a day, the full pass played for real, then what the day never plays: the night
|
|
4
|
-
# tests and the measures of time (the time budget benches and the time witnesses). During the day `npm run verifier` (the
|
|
5
|
-
# what the changes since the last green touch (scripts/
|
|
4
|
+
# tests and the measures of time (the time budget benches and the time witnesses). During the day `npm run verifier` (the final pass's) plays
|
|
5
|
+
# what the changes since the last green touch (scripts/activites.mjs,
|
|
6
6
|
# scripts/dernier-vert.mjs); the module of the project's language plays each step
|
|
7
7
|
# (scripts/jointure.d.ts). The paragraphs below are the details only this script knows (marks,
|
|
8
8
|
# files, bounds, the text of a night ticket).
|
|
@@ -69,20 +69,8 @@
|
|
|
69
69
|
# depended on a duration, one under load) waits for rest (`npx grillhouse pression attendre`,
|
|
70
70
|
# bound 15 min) and plays once more; green then, the night goes on; à repasser again, or no rest in the bound, the night
|
|
71
71
|
# ends there, « à repasser », red if the full pass is.
|
|
72
|
-
# - The
|
|
73
|
-
# `
|
|
74
|
-
# `tests-de-nuit --hors-du-poste`). The measures of time play on PC3, on dedicated cores, unless
|
|
75
|
-
# the flow declares a job that plays them (a command `tests-de-nuit --mesures`, as the flow of
|
|
76
|
-
# Grillhouse: scripts/flux-de-la-nuit.mjs): then that job's verdict, read for the commit of the
|
|
77
|
-
# night, stands for them, and PC3 plays them only when the job was interrupted. The night of PC3
|
|
78
|
-
# plays the tests tagged @poste, then the measures (`tests-de-nuit --du-poste`, on its part), then
|
|
79
|
-
# reads the flow of its commit by `gh`
|
|
80
|
-
# (scripts/repli-de-la-nuit.mjs): a tranche whose job has not started 60 minutes after the flow's
|
|
81
|
-
# hour is cancelled and played on PC3, a tranche started then interrupted plays whole again, a
|
|
82
|
-
# tranche finished on PC2, green or red, is never replayed; the log says which tranches played
|
|
83
|
-
# where. Each part keeps its verdict (scripts/verdict-de-la-nuit.mjs: `nuit/verdict` for PC3,
|
|
84
|
-
# `nuit/verdict-pc2`), the night is red when either is, and a red tranche opens or comments its
|
|
85
|
-
# night ticket.
|
|
72
|
+
# - The night of the poste plays nothing of PC2: the part of PC2 is played from PC3 by ssh, by the
|
|
73
|
+
# activity `jouerLaNuitDePc2` of the workflow of the nights, which writes `nuit/verdict-pc2`.
|
|
86
74
|
# - « À repasser » (exit 75): neither green nor red. The last green stays, no ticket opens,
|
|
87
75
|
# the log says so; the next night plays again.
|
|
88
76
|
# - The project's night script: `grillhouse.nuit` in the package.json of the commit it plays names
|
|
@@ -102,15 +90,15 @@
|
|
|
102
90
|
# workspaces at the end of a pipeline: a copy whose commits and local work have all entered
|
|
103
91
|
# main by their content goes, and its branch (main and a branch another copy holds stay); a copy
|
|
104
92
|
# refused (commits or work not entered, a lock) or held by a running circuit (its ticket in progress, its
|
|
105
|
-
# `<copie>.travail`, the lock of the
|
|
93
|
+
# `<copie>.travail`, the lock of the queue) stays, its log line naming
|
|
106
94
|
# why and the place it holds, a kept copy whose ticket is closed losing what the tools of its
|
|
107
95
|
# languages wrote there. The night names its own copy to the removal, its steps played: the copy
|
|
108
96
|
# stays, and loses what the tools of its languages wrote there (`target`, `.turbo`), its
|
|
109
97
|
# `node_modules` kept, which its next preparation would remove anyway. The
|
|
110
98
|
# removal never changes the night's verdict; the end of each circuit runs it too
|
|
111
99
|
# (scripts/circuit.mjs), the night's copy untouched.
|
|
112
|
-
# - It takes no lock of the
|
|
113
|
-
#
|
|
100
|
+
# - It takes no lock of the queue (scripts/integration/file.mjs): the queue runs during the night,
|
|
101
|
+
# in its own copy.
|
|
114
102
|
# - Its log is <git common dir>/nuit/<date>.log. Green: HEAD becomes the last green commit
|
|
115
103
|
# (<git common dir>/nuit/dernier-vert), only once the measures of time were played and are green,
|
|
116
104
|
# by PC3 or by the flow's job for that commit. Red: the red tasks, each grouped by its cause as an
|
|
@@ -178,12 +166,6 @@ copie="$racine/.claude/worktrees/nuit"
|
|
|
178
166
|
etapes=()
|
|
179
167
|
taches=()
|
|
180
168
|
rejeux=()
|
|
181
|
-
# The part of PC2 of the night (the tranches of the Nuit flow), when the project's flow plays on PC2:
|
|
182
|
-
# its red steps and tasks, kept apart from PC3's so that each part has its own verdict, and its exit
|
|
183
|
-
# code (empty when the project has no part on PC2; 75 when a tranche is still to play there).
|
|
184
|
-
etapes_pc2=()
|
|
185
|
-
taches_pc2=()
|
|
186
|
-
code_pc2=
|
|
187
169
|
# Gets the copy ready on HEAD: detached, cleaned, its submodules set; `partages` holds the list the
|
|
188
170
|
# pose fixes, which every mount gets. Prints the reason on failure.
|
|
189
171
|
partages=
|
|
@@ -196,81 +178,6 @@ preparer() {
|
|
|
196
178
|
fi
|
|
197
179
|
partages=$(bash "$ici/sous-modules.sh" pose "$copie")
|
|
198
180
|
}
|
|
199
|
-
# The part of PC2: reads the Nuit flow of the commit the night plays by `gh` (scripts/repli-de-la-nuit.mjs), which cancels the
|
|
200
|
-
# run when a tranche has not started 60 minutes after the flow's hour, then plays on PC3, whole, each
|
|
201
|
-
# tranche not played on PC2 (never one finished there, green or red). A tranche still running or
|
|
202
|
-
# waiting leaves the part of PC2 « à repasser » (75). The statement says which tranches played where.
|
|
203
|
-
repli() {
|
|
204
|
-
local depot decision ligne
|
|
205
|
-
code_pc2=0
|
|
206
|
-
if ! depot="$(cd "$racine" && gh repo view --json nameWithOwner -q .nameWithOwner 2>/dev/null)" || [ -z "$depot" ]; then
|
|
207
|
-
echo "⏱ le repli de la nuit ne lit pas le dépôt GitHub (gh) : la part de PC2 reste à repasser."
|
|
208
|
-
code_pc2=75
|
|
209
|
-
return
|
|
210
|
-
fi
|
|
211
|
-
if ! decision="$(node "$ici/repli-de-la-nuit.mjs" "$depot" "$tranches" "" "$tete")"; then
|
|
212
|
-
echo "⏱ le repli de la nuit ne lit pas le flux Nuit : la part de PC2 reste à repasser."
|
|
213
|
-
code_pc2=75
|
|
214
|
-
return
|
|
215
|
-
fi
|
|
216
|
-
local lignes rejouer= rouges_pc2= attend= mesures_du_flux=
|
|
217
|
-
lignes="$(printf '%s' "$decision" | node -e 'let s="";process.stdin.on("data",d=>s+=d).on("end",()=>{const d=JSON.parse(s);const l=k=>(d[k]??[]).join(" ");process.stdout.write([...["pc2","pc3","rouges","enAttente","enCours"].map(k=>k+"\t"+l(k)),"mesures\t"+d.mesures].join("\n")+"\n")})')"
|
|
218
|
-
while IFS= read -r ligne; do
|
|
219
|
-
case "$ligne" in
|
|
220
|
-
pc2$'\t'*) echo "relevé de la nuit : tranches jouées sur PC2 : ${ligne#pc2$'\t'}" ;;
|
|
221
|
-
pc3$'\t'*) rejouer="${ligne#pc3$'\t'}"; echo "relevé de la nuit : tranches jouées sur PC3 : ${rejouer:-aucune}" ;;
|
|
222
|
-
rouges$'\t'*) rouges_pc2="${ligne#rouges$'\t'}" ;;
|
|
223
|
-
mesures$'\t'*) mesures_du_flux="${ligne#mesures$'\t'}" ;;
|
|
224
|
-
enAttente$'\t'*|enCours$'\t'*) attend="$attend ${ligne#*$'\t'}" ;;
|
|
225
|
-
esac
|
|
226
|
-
done <<< "$lignes"
|
|
227
|
-
local t code
|
|
228
|
-
for t in $rouges_pc2; do
|
|
229
|
-
echo "✗ la tranche $t de la nuit est rouge sur PC2."
|
|
230
|
-
etapes_pc2+=("la tranche $t de la nuit sur PC2")
|
|
231
|
-
taches_pc2+=("la tranche $t de la nuit sur PC2")
|
|
232
|
-
done
|
|
233
|
-
for t in $rejouer; do
|
|
234
|
-
(cd "$copie" && monter node "$ici/commande-du-langage.mjs" tests-de-nuit --hors-du-poste --tranche "$t/$tranches")
|
|
235
|
-
code=$?
|
|
236
|
-
if [ "$code" -ne 0 ] && [ "$code" -ne 75 ]; then
|
|
237
|
-
echo "✗ la tranche $t, rejouée sur PC3, est rouge."
|
|
238
|
-
etapes_pc2+=("la tranche $t de la nuit, rejouée sur PC3")
|
|
239
|
-
taches_pc2+=("la tranche $t de la nuit sur PC3 (repli)")
|
|
240
|
-
elif [ "$code" -eq 75 ]; then
|
|
241
|
-
attend="$attend $t"
|
|
242
|
-
fi
|
|
243
|
-
done
|
|
244
|
-
# The measures of time: the flow's job plays them when its file declares one; the night of the
|
|
245
|
-
# poste plays them itself otherwise (tests-de-nuit --du-poste), so no last green without them.
|
|
246
|
-
if node "$ici/flux-de-la-nuit.mjs" mesures "$copie"; then
|
|
247
|
-
echo "relevé de la nuit : mesures de temps du flux : $mesures_du_flux"
|
|
248
|
-
case "$mesures_du_flux" in
|
|
249
|
-
rouge)
|
|
250
|
-
echo "✗ les mesures de temps du flux sont rouges sur PC2."
|
|
251
|
-
etapes_pc2+=("les mesures de temps de la nuit sur PC2")
|
|
252
|
-
taches_pc2+=("les mesures de temps de la nuit sur PC2") ;;
|
|
253
|
-
a-rejouer)
|
|
254
|
-
(cd "$copie" && monter node "$ici/commande-du-langage.mjs" tests-de-nuit --mesures)
|
|
255
|
-
code=$?
|
|
256
|
-
if [ "$code" -eq 75 ]; then
|
|
257
|
-
attend="$attend mesures"
|
|
258
|
-
elif [ "$code" -ne 0 ]; then
|
|
259
|
-
echo "✗ les mesures de temps, rejouées sur PC3, sont rouges."
|
|
260
|
-
etapes_pc2+=("les mesures de temps de la nuit, rejouées sur PC3")
|
|
261
|
-
taches_pc2+=("les mesures de temps de la nuit sur PC3 (repli)")
|
|
262
|
-
fi ;;
|
|
263
|
-
verte) ;;
|
|
264
|
-
*) attend="$attend mesures" ;;
|
|
265
|
-
esac
|
|
266
|
-
fi
|
|
267
|
-
if [ "${#etapes_pc2[@]}" -gt 0 ]; then
|
|
268
|
-
code_pc2=1
|
|
269
|
-
elif [ -n "${attend// /}" ]; then
|
|
270
|
-
echo "⏱ la part de PC2 reste à repasser : tranche(s) en cours, en attente ou à repasser :$attend."
|
|
271
|
-
code_pc2=75
|
|
272
|
-
fi
|
|
273
|
-
}
|
|
274
181
|
# Plays the copy; its status is the night's verdict. An existing copy that does not get ready is
|
|
275
182
|
# removed (scripts/retirer-copie.sh --jetable) and created again, once.
|
|
276
183
|
jouer() {
|
|
@@ -400,21 +307,8 @@ process.exit(paquets(process.argv[2]).some(p => p.pkg.name === "@roomi-fields/gr
|
|
|
400
307
|
rejeux+=("")
|
|
401
308
|
fi
|
|
402
309
|
fi
|
|
403
|
-
# A project whose Nuit flow plays on PC2 (its runner label `pc2`) leaves PC2 the night tests that
|
|
404
|
-
# do not need the poste: PC3 plays the tests tagged @poste, then the tranches PC2 did not play
|
|
405
|
-
# (the fallback, scripts/repli-de-la-nuit.mjs). The measures of time play on PC3 too, unless the
|
|
406
|
-
# flow declares a job that plays them (`tests-de-nuit --mesures`, scripts/flux-de-la-nuit.mjs,
|
|
407
|
-
# the flow of Grillhouse): then the verdict of its job, read for the commit of the night, counts.
|
|
408
|
-
# The last green is set only when the measures were played and are green, by PC3 or by that job.
|
|
409
|
-
local sur_pc2=0 tranches=
|
|
410
|
-
if grep -q "\bpc2\b" "$copie/.github/workflows/nuit.yml" 2>/dev/null; then
|
|
411
|
-
sur_pc2=1
|
|
412
|
-
tranches="$(sed -n 's/^ TRANCHES: *\([0-9]*\).*/\1/p' "$copie/.github/workflows/nuit.yml")"
|
|
413
|
-
fi
|
|
414
310
|
bancs() {
|
|
415
|
-
|
|
416
|
-
[ "$sur_pc2" -eq 0 ] || args=(--du-poste)
|
|
417
|
-
(cd "$copie" && monter node "$ici/commande-du-langage.mjs" tests-de-nuit "${args[@]}")
|
|
311
|
+
(cd "$copie" && monter node "$ici/commande-du-langage.mjs" tests-de-nuit)
|
|
418
312
|
}
|
|
419
313
|
bancs
|
|
420
314
|
code=$?
|
|
@@ -439,9 +333,6 @@ process.exit(paquets(process.argv[2]).some(p => p.pkg.name === "@roomi-fields/gr
|
|
|
439
333
|
taches+=("les bancs de temps et les tests de nuit")
|
|
440
334
|
rejeux+=("")
|
|
441
335
|
fi
|
|
442
|
-
if [ "$sur_pc2" -eq 1 ]; then
|
|
443
|
-
repli
|
|
444
|
-
fi
|
|
445
336
|
if [ -n "$nuit" ] && ! monter npm --prefix "$copie" run "$nuit"; then
|
|
446
337
|
echo "✗ le script de nuit du projet \`npm run $nuit\` (grillhouse.nuit) a échoué."
|
|
447
338
|
etapes+=("le script de nuit du projet (npm run $nuit, grillhouse.nuit)")
|
|
@@ -463,20 +354,6 @@ verdict=$?
|
|
|
463
354
|
# The project's durable verdict, read by the board: green on 0, red on any other code but 75, which
|
|
464
355
|
# writes nothing (the previous verdict stays).
|
|
465
356
|
node "$ici/verdict-de-la-nuit.mjs" "$commun" "$verdict" pc3 >> "$journal" 2>&1 || true
|
|
466
|
-
# The part of PC2, when the project has one: its own durable verdict, and the night's, which is red
|
|
467
|
-
# when either part is red and « à repasser » while a tranche of PC2 is still to play.
|
|
468
|
-
if [ -n "$code_pc2" ]; then
|
|
469
|
-
node "$ici/verdict-de-la-nuit.mjs" "$commun" "$code_pc2" pc2 >> "$journal" 2>&1 || true
|
|
470
|
-
if [ "$code_pc2" -eq 1 ]; then
|
|
471
|
-
etapes+=("${etapes_pc2[@]}")
|
|
472
|
-
taches+=("${taches_pc2[@]}")
|
|
473
|
-
for _ in "${taches_pc2[@]}"; do rejeux+=(""); done
|
|
474
|
-
verdict=1
|
|
475
|
-
elif [ "$code_pc2" -eq 75 ] && [ "$verdict" -eq 0 ]; then
|
|
476
|
-
verdict=75
|
|
477
|
-
fi
|
|
478
|
-
fi
|
|
479
|
-
|
|
480
357
|
if [ "$verdict" -eq 75 ]; then
|
|
481
358
|
echo "⏱ à repasser : ${tete:0:7} n'est ni vert ni rouge, la machine est restée chargée ; le dernier vert reste, aucun ticket, la nuit suivante rejoue." >> "$journal"
|
|
482
359
|
exit 75
|
package/scripts/paquets.mjs
CHANGED
|
@@ -33,7 +33,7 @@ export const TYPAGE = 'typecheck';
|
|
|
33
33
|
|
|
34
34
|
// The tag of a test that declares the files it reads: a line `// @lit <motif> …` of the comment at
|
|
35
35
|
// the head of the file, before its first line of code, as the tag `@poste`.
|
|
36
|
-
const ETIQUETTE_DE_LECTURE = /^\/\/\s*@lit
|
|
36
|
+
const ETIQUETTE_DE_LECTURE = /^\/\/\s*@lit(?=\s|$)(.*)$/;
|
|
37
37
|
|
|
38
38
|
/**
|
|
39
39
|
* The patterns the text <texte> of a test file declares it reads, as the `data` of a Bazel target:
|