repowarden 4.7.2-next.6 → 4.8.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/README.md +5 -1
- package/bin/app +24 -10
- package/bin/bot +231 -0
- package/bin/bots +370 -0
- package/bin/migrer +205 -0
- package/bin/proteger +31 -2
- package/bin/repowarden +7 -1
- package/bin/statut +12 -0
- package/bin/tickets +5 -7
- package/hooks/lib/i18n/en.sh +120 -2
- package/hooks/lib/i18n/fr.sh +120 -2
- package/install.sh +19 -1
- package/package.json +1 -1
package/bin/repowarden
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
# repowarden état du poste et étape suivante
|
|
4
4
|
# repowarden statut (idem)
|
|
5
5
|
# repowarden install [--global] [--lang fr|en] active les hooks (install.sh)
|
|
6
|
+
# repowarden bots bots du dépôt GitHub (CI, releases, tickets…)
|
|
6
7
|
# repowarden uninstall [--global] [--purge] les retire (avant npm uninstall -g)
|
|
7
8
|
# repowarden cc assistant de commit
|
|
8
9
|
# repowarden code-mort nouveau code mort de la branche
|
|
@@ -16,8 +17,10 @@
|
|
|
16
17
|
# repowarden run list [--workflow <nom>] liste les runs récents
|
|
17
18
|
# repowarden tickets init suivi des tickets (GitHub)
|
|
18
19
|
# repowarden proteger [options] protection des branches (GitHub)
|
|
20
|
+
# repowarden migrer [--pr] [--hooks] passage de repogarde à repowarden
|
|
19
21
|
# repowarden npm-publication publication npm automatique
|
|
20
22
|
# repowarden app init GitHub App des workflows (une fois)
|
|
23
|
+
# repowarden bot [init|rapport] bot d'organisation (dépôt de pilotage)
|
|
21
24
|
# repowarden --version
|
|
22
25
|
set -euo pipefail
|
|
23
26
|
|
|
@@ -35,7 +38,7 @@ source "$ROOT/hooks/lib/ui.sh"
|
|
|
35
38
|
# shellcheck source=../hooks/lib/i18n.sh
|
|
36
39
|
source "$ROOT/hooks/lib/i18n.sh"
|
|
37
40
|
|
|
38
|
-
aide() { sed -n '2,
|
|
41
|
+
aide() { sed -n '2,24p' "$ROOT/bin/repowarden" | sed 's/^# \{0,1\}//'; }
|
|
39
42
|
|
|
40
43
|
commande="${1:-}"
|
|
41
44
|
[ $# -eq 0 ] || shift
|
|
@@ -61,8 +64,11 @@ case "$commande" in
|
|
|
61
64
|
run-list) exec bash "$ROOT/bin/run-list" "$@" ;;
|
|
62
65
|
pr-checks) exec bash "$ROOT/bin/pr-checks" "$@" ;;
|
|
63
66
|
proteger | protect) exec bash "$ROOT/bin/proteger" "$@" ;;
|
|
67
|
+
migrer | migrate) exec bash "$ROOT/bin/migrer" "$@" ;;
|
|
64
68
|
npm-publication | npm-publish) exec bash "$ROOT/bin/npm-publication" "$@" ;;
|
|
65
69
|
app) exec bash "$ROOT/bin/app" "$@" ;;
|
|
70
|
+
bots) exec bash "$ROOT/bin/bots" "$@" ;;
|
|
71
|
+
bot) exec bash "$ROOT/bin/bot" "$@" ;;
|
|
66
72
|
-v | --version | version)
|
|
67
73
|
repowarden_version_r "$ROOT"
|
|
68
74
|
echo "$REPLY"
|
package/bin/statut
CHANGED
|
@@ -70,6 +70,18 @@ if [ -n "$GIT_TOPLEVEL" ]; then
|
|
|
70
70
|
attention_t st.repo_lefthook "$f"
|
|
71
71
|
break
|
|
72
72
|
done
|
|
73
|
+
# Anciens noms (configuration, workflows de l'ancien dépôt, que GitHub ne
|
|
74
|
+
# redirige plus) : la migration les remplace
|
|
75
|
+
if [ -e "$GIT_TOPLEVEL/.repogarde.conf" ] || [ -d "$GIT_TOPLEVEL/.repogarde" ] ||
|
|
76
|
+
grep -qs repogarde "$GIT_TOPLEVEL"/.github/workflows/*.y*ml; then
|
|
77
|
+
attention_t st.repo_migrate
|
|
78
|
+
suivant="${suivant:-repowarden migrer}"
|
|
79
|
+
fi
|
|
80
|
+
# Branche develop présente, flux non déclaré : traité comme « main seule »
|
|
81
|
+
cfg_r integrationBranch ""
|
|
82
|
+
if [ -z "$REPLY" ] && git rev-parse -q --verify refs/remotes/origin/develop >/dev/null; then
|
|
83
|
+
attention_t st.repo_develop_undeclared
|
|
84
|
+
fi
|
|
73
85
|
cfg_r version ""
|
|
74
86
|
if [ -n "$REPLY" ]; then
|
|
75
87
|
attendue="${REPLY#v}"
|
package/bin/tickets
CHANGED
|
@@ -141,13 +141,11 @@ GH_REPO="$REPO" AUTO_VALIDATE="${AUTO_VALIDATE:-maintainers}" "$ROOT/ci/tickets.
|
|
|
141
141
|
|
|
142
142
|
# Afficher l'état de ticketAutoCreate
|
|
143
143
|
echo
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
hint "$_T"
|
|
150
|
-
fi
|
|
144
|
+
cfg_r ticketAutoCreate false
|
|
145
|
+
case "$REPLY" in
|
|
146
|
+
true | oui | yes) dim_t tk.init_auto_create_on ;;
|
|
147
|
+
*) dim_t tk.init_auto_create_off ;;
|
|
148
|
+
esac
|
|
151
149
|
|
|
152
150
|
echo
|
|
153
151
|
ok_t tk.init_done
|
package/hooks/lib/i18n/en.sh
CHANGED
|
@@ -100,6 +100,7 @@ _msg_en() {
|
|
|
100
100
|
install.replaced) _M="core.hooksPath (%s) was '%s', replaced." ;;
|
|
101
101
|
install.enabled) _M="Hooks enabled (%s) → %s" ;;
|
|
102
102
|
install.local_wins) _M="A local core.hooksPath (e.g. husky) still takes precedence in that repository." ;;
|
|
103
|
+
install.bots_never) _M="Repository bots will no longer be offered (repowarden.bots = off); on demand: repowarden bots" ;;
|
|
103
104
|
install.lang_set) _M="Message language: English (change: %s --global --lang fr)" ;;
|
|
104
105
|
install.lang_invalid) _M="--lang: fr or en." ;;
|
|
105
106
|
install.keys_migrated) _M="repogarde.* settings (%s) renamed to repowarden.*" ;;
|
|
@@ -232,6 +233,7 @@ _msg_en() {
|
|
|
232
233
|
ci.check.16) _M="Target \"%s\" matches the flow." ;;
|
|
233
234
|
ci.check.17) _M="PR from \"%s\" to \"%s\": expected target %s (integrationBranch setting)." ;;
|
|
234
235
|
ci.check.18) _M=" Fix: change the PR base branch (Edit, next to the title), or gh pr edit --base %s" ;;
|
|
236
|
+
ci.check.develop_undeclared) _M="PR %s → %s: the develop branch exists but .repowarden.conf does not declare the develop → main flow. Add integrationBranch = develop (work then goes through develop), or delete develop if the project does not want it." ;;
|
|
235
237
|
ci.check.19) _M="gitleaks not installed: run ci/install-tool.sh gitleaks before this script." ;;
|
|
236
238
|
ci.check.20) _M="Working tree modified before the check: formatting cannot be verified." ;;
|
|
237
239
|
ci.check.21) _M="A formatter failed (syntax error, or tool / dependency unavailable): see the log above." ;;
|
|
@@ -296,21 +298,57 @@ _msg_en() {
|
|
|
296
298
|
ci.proteger.verify_ok) _M="Online rules up to date." ;;
|
|
297
299
|
ci.proteger.delivery) _M=" delivery into main: %s approval(s) required (moving to a new version); auto-merge of work PRs into develop: %s" ;;
|
|
298
300
|
ci.proteger.methods_flow) _M="main: merge commit; %s: squash or merge commit" ;;
|
|
301
|
+
ci.proteger.livraison_check) _M=" \"livraison\" check required on the main branch (prerelease published, protection in place)" ;;
|
|
299
302
|
ci.proteger.tags_org) _M="reserved for workflows" ;;
|
|
300
303
|
ci.proteger.tags_user) _M="neither moved nor deleted (personal account: creation allowed)" ;;
|
|
301
304
|
ci.proteger.tags_none) _M="not protected (--sans-tags)" ;;
|
|
302
305
|
ci.proteger.unknown_team) _M="Unknown or inaccessible team: %s (format @organisation/team)" ;;
|
|
303
306
|
ci.proteger.unknown_user) _M="Unknown user: %s" ;;
|
|
307
|
+
mig.no_major) _M="repowarden major version not found (%s): REPOWARDEN_MAJEURE=4 repowarden migrer." ;;
|
|
308
|
+
mig.dirty) _M="Uncommitted changes: commit or stash before repowarden migrer --pr." ;;
|
|
309
|
+
mig.pr_open) _M="Migration PR already open (%s): nothing to do." ;;
|
|
310
|
+
mig.both) _M="%s and %s both exist: keep the second, merge then delete the first by hand." ;;
|
|
311
|
+
mig.conf) _M=".repogarde.conf → .repowarden.conf ([repowarden] section, version updated)" ;;
|
|
312
|
+
mig.dir) _M=".repogarde/ → .repowarden/" ;;
|
|
313
|
+
mig.workflow) _M="%s: uses: to simdevWarden/repowarden, old names replaced" ;;
|
|
314
|
+
mig.renamed) _M="%s → %s" ;;
|
|
315
|
+
mig.tickets_events) _M="%s: ticket tracking events completed (push, review, assignment, closing): prefilled draft PR on the first push" ;;
|
|
316
|
+
mig.tickets_labels) _M="Tracking labels (type: feat, statuses…): repowarden tickets init (can be rerun, rewrites no file)" ;;
|
|
317
|
+
mig.hooks_moved) _M="Leftover lefthook hooks (%s) moved to %s" ;;
|
|
318
|
+
mig.hooks_left) _M="Leftover lefthook hooks in .git/hooks (%s), ignored: repowarden migrer --hooks to set them aside." ;;
|
|
319
|
+
mig.lefthook_conf) _M="%s: lefthook is no longer supported; move its commands to .repowarden/<hook>, then delete this file." ;;
|
|
320
|
+
mig.secrets) _M="Secrets or variables renamed in the workflows, to recreate under the new name (Settings → Secrets and variables):%s" ;;
|
|
321
|
+
mig.remaining) _M="Still mention repogarde (to review, not changed): %s" ;;
|
|
322
|
+
mig.nothing) _M="Nothing to migrate: the project already uses the repowarden names." ;;
|
|
323
|
+
mig.next) _M="Next: check the diff, then repowarden proteger (the required check is now called repowarden)." ;;
|
|
324
|
+
mig.commit_subject) _M="move from repogarde to repowarden v%s" ;;
|
|
325
|
+
mig.commit_body) _M="Old names and paths replaced by repowarden migrer (docs/migration-v4.md): GitHub no longer redirects the old repository's reusable workflows." ;;
|
|
326
|
+
mig.pr_body) _M="Migration from repogarde to repowarden, made by repowarden migrer (docs/migration-v4.md)." ;;
|
|
327
|
+
mig.pr_after) _M="After merging: run repowarden proteger (the required check is now called repowarden) and recreate any REPOGARDE_* secrets under their new name." ;;
|
|
328
|
+
mig.pr_created) _M="Migration PR opened (%s)." ;;
|
|
329
|
+
st.repo_migrate) _M="Old repogarde names in this project: repowarden migrer" ;;
|
|
330
|
+
st.repo_develop_undeclared) _M="The develop branch exists but the develop → main flow is not declared: add integrationBranch = develop to .repowarden.conf (otherwise work can go straight into main)." ;;
|
|
304
331
|
ci.proteger.legacy_taken) _M="Ruleset \"%s\": old ruleset \"%s\" taken over (repogarde check removed)." ;;
|
|
305
332
|
ci.proteger.legacy_left) _M="Old ruleset \"%s\" (id %s): still requires the repogarde check, removed in v4, and blocks its branches. Delete it: Settings → Rules → Rulesets, or gh api -X DELETE repos/%s/rulesets/%s." ;;
|
|
306
333
|
ci.proteger.verify_legacy) _M="%s (id %s): old ruleset, still requires the repogarde check (removed in v4)" ;;
|
|
307
334
|
ci.proteger.api_error) _M="Ruleset \"%s\" rejected by GitHub: %s" ;;
|
|
308
335
|
ci.proteger.incomplete) _M="Incomplete protection: see the errors above." ;;
|
|
309
|
-
ci.
|
|
336
|
+
ci.proteger.rulesets_unavailable) _M="Rulesets unavailable for %s: GitHub refuses them on a private repository of a free account. Make the repository public, or move to GitHub Pro / Team; the other settings are applied." ;;
|
|
337
|
+
ci.proteger.tags_fallback) _M="Tags ruleset: \"GitHub Actions\" bypass refused in this organization; tags protected as on a personal account (not moved or deleted, creation allowed)." ;;
|
|
338
|
+
ci.version.usage) _M="Usage: ci/version.sh next|notes|notes-livraison [ref]" ;;
|
|
310
339
|
ci.version.breaking) _M="Breaking changes" ;;
|
|
311
340
|
ci.version.features) _M="Features" ;;
|
|
312
341
|
ci.version.fixes) _M="Bug fixes" ;;
|
|
313
342
|
ci.version.maintenance) _M="Maintenance" ;;
|
|
343
|
+
ci.version.summary) _M="In short" ;;
|
|
344
|
+
ci.version.todo) _M="To do" ;;
|
|
345
|
+
ci.version.update) _M="Update" ;;
|
|
346
|
+
ci.version.tickets) _M="Delivered tickets" ;;
|
|
347
|
+
ci.livraison.protection) _M="Protection of the %s flow missing (merge commit, no deletion): run repowarden proteger" ;;
|
|
348
|
+
ci.livraison.maintenance) _M="Maintenance only: no version to publish" ;;
|
|
349
|
+
ci.livraison.non_exigee) _M="%s: prerelease not required" ;;
|
|
350
|
+
ci.livraison.ok) _M="%s: prerelease tested, deliverable" ;;
|
|
351
|
+
ci.livraison.preversion) _M="%s: no prerelease %s; wait for the evening one, or Actions → release → Run workflow on %s" ;;
|
|
314
352
|
ci.install_tool.os) _M="Unsupported system: %s" ;;
|
|
315
353
|
ci.install_tool.arch) _M="Unsupported architecture: %s" ;;
|
|
316
354
|
ci.install_tool.unknown) _M="Unknown tool: %s" ;;
|
|
@@ -420,13 +458,93 @@ _msg_en() {
|
|
|
420
458
|
app.server_failed) _M="Local page did not start." ;;
|
|
421
459
|
app.open) _M="Open %s then click GitHub's green button." ;;
|
|
422
460
|
app.no_code) _M="No answer from GitHub (creation cancelled, or 15 min timeout)." ;;
|
|
423
|
-
app.created) _M="App %s created; credentials stored (variable
|
|
461
|
+
app.created) _M="App %s created; credentials stored (variable %s, secret %s)." ;;
|
|
424
462
|
app.step_install) _M="Installing on the repository" ;;
|
|
425
463
|
app.installed) _M="App %s installed on %s." ;;
|
|
426
464
|
app.not_installed) _M="App %s not installed on %s yet: run repowarden app init again once installed." ;;
|
|
427
465
|
app.check_in_ci) _M="Installation checked by the first ticket tracking run (\"Jeton de l'App\" step); to install it: %s" ;;
|
|
428
466
|
app.done) _M="repowarden workflows now use the App: what they do triggers the other workflows." ;;
|
|
429
467
|
app.next) _M="Without the App (variable and secret missing), they fall back to the Actions token." ;;
|
|
468
|
+
app.bot_all_repos) _M="Organization bot: when installing, choose \"All repositories\" (new repositories are covered automatically; only those with a .repowarden.conf are managed)." ;;
|
|
469
|
+
bot.init_exists) _M="%s already exists: left unchanged." ;;
|
|
470
|
+
bot.init_done) _M="%s written: runs every night, and on demand (Actions → bot → Run workflow, dry-run box to see without changing anything)." ;;
|
|
471
|
+
bot.init_next) _M="Bot credentials in this repository: repowarden app init --bot (once, installed on \"All repositories\")." ;;
|
|
472
|
+
bot.no_report) _M="Report not found: %s" ;;
|
|
473
|
+
bot.report_updated) _M="Report published (issue #%s updated)." ;;
|
|
474
|
+
bot.report_created) _M="Report published (new issue)." ;;
|
|
475
|
+
bot.col_repo) _M="Repository" ;;
|
|
476
|
+
bot.col_mode) _M="Mode" ;;
|
|
477
|
+
bot.col_protection) _M="Protection" ;;
|
|
478
|
+
bot.col_migration) _M="Migration" ;;
|
|
479
|
+
bot.repo) _M="%s" ;;
|
|
480
|
+
bot.not_adopted) _M="not adopted (no .repowarden.conf)" ;;
|
|
481
|
+
bot.ignored) _M="ignored (bot = off)" ;;
|
|
482
|
+
bot.mode_invalid) _M="bot = %s: auto, pr or off expected" ;;
|
|
483
|
+
bot.clone_failed) _M="clone failed: %s" ;;
|
|
484
|
+
bot.prot_ok) _M="up to date" ;;
|
|
485
|
+
bot.prot_stale) _M="⚠ outdated: repowarden proteger" ;;
|
|
486
|
+
bot.prot_applied) _M="✔ applied" ;;
|
|
487
|
+
bot.error) _M="✖ %s" ;;
|
|
488
|
+
bot.mig_none) _M="nothing to migrate" ;;
|
|
489
|
+
bot.mig_open) _M="PR already open" ;;
|
|
490
|
+
bot.mig_todo) _M="⚠ to migrate: repowarden migrer" ;;
|
|
491
|
+
bot.mig_pr) _M="✔ PR opened" ;;
|
|
492
|
+
bot.report_head) _M="Run of %s." ;;
|
|
493
|
+
bot.report_dry) _M="Preview (dry-run): nothing was changed." ;;
|
|
494
|
+
bot.failed) _M="Run finished with %s error(s): see the report." ;;
|
|
495
|
+
bots.skip) _M="Repository bots not offered (%s): later, repowarden bots" ;;
|
|
496
|
+
bots.why_repo) _M="not in a Git repository" ;;
|
|
497
|
+
bots.why_github) _M="repository not on GitHub" ;;
|
|
498
|
+
bots.why_gh) _M="gh missing: https://cli.github.com" ;;
|
|
499
|
+
bots.why_gh_login) _M="gh not logged in: gh auth login" ;;
|
|
500
|
+
bots.why_admin) _M="repository admin rights needed" ;;
|
|
501
|
+
bots.why_tty) _M="no terminal to answer the questions" ;;
|
|
502
|
+
bots.ask_global) _M="Set up this repository's bots (CI, releases, tickets, protection…)? Nothing is done without your consent, bot by bot." ;;
|
|
503
|
+
bots.later) _M="No bot set up. Later: repowarden bots" ;;
|
|
504
|
+
bots.flow_question) _M="Branch flow:" ;;
|
|
505
|
+
bots.flow_main) _M="%s only: every PR is merged into it (squash)" ;;
|
|
506
|
+
bots.flow_develop) _M="develop → %s: work is integrated into develop (prereleases), only develop goes into %s (delivery)" ;;
|
|
507
|
+
bots.ask_create_develop) _M="The develop branch does not exist on GitHub: create it from the default branch?" ;;
|
|
508
|
+
bots.one_by_one) _M="One consent per bot (Enter: yes):" ;;
|
|
509
|
+
bots.app_present) _M="Workflows GitHub App already set up: used by the other bots." ;;
|
|
510
|
+
bots.desc_ci) _M=" CI: checks every PR (messages, branch, secrets, formatting, tests); writes .github/workflows/repowarden.yml" ;;
|
|
511
|
+
bots.desc_release) _M=" Releases: version, notes and tag computed from the commits; writes .github/workflows/release.yml" ;;
|
|
512
|
+
bots.desc_nettoyage) _M=" Cleanup: deletes merged branches, keeps long-lived branches; writes .github/workflows/nettoyage.yml" ;;
|
|
513
|
+
bots.desc_tickets) _M=" Tickets: ticket first, prefilled PR, statuses up to production; labels, ticket template, workflow (repowarden tickets init)" ;;
|
|
514
|
+
bots.desc_app) _M=" GitHub App: what the bots do triggers the other workflows; created in the browser (repowarden app init)" ;;
|
|
515
|
+
bots.desc_proteger) _M=" Protection: PR and checks required, no deletion or force push; changes GitHub settings (repowarden proteger)" ;;
|
|
516
|
+
bots.desc_npm) _M=" npm: publishes the package on every release, without a token (repowarden npm-publication)" ;;
|
|
517
|
+
bots.ask_ci) _M="CI?" ;;
|
|
518
|
+
bots.ask_release) _M="Releases?" ;;
|
|
519
|
+
bots.ask_nettoyage) _M="Branch cleanup?" ;;
|
|
520
|
+
bots.ask_tickets) _M="Ticket tracking?" ;;
|
|
521
|
+
bots.ask_app) _M="GitHub App?" ;;
|
|
522
|
+
bots.ask_proteger) _M="Branch protection?" ;;
|
|
523
|
+
bots.ask_npm) _M="npm publishing?" ;;
|
|
524
|
+
bots.preview) _M="Preview" ;;
|
|
525
|
+
bots.prev_develop) _M="branch %s created on GitHub from %s" ;;
|
|
526
|
+
bots.prev_conf) _M=".repowarden.conf: integrationBranch = %s, protected branches" ;;
|
|
527
|
+
bots.prev_review) _M=".repowarden.conf: delivery approved by reviewing its PR (no GitHub App)" ;;
|
|
528
|
+
bots.prev_kept) _M="%s exists: kept as is (difference with the template: %s line(s))" ;;
|
|
529
|
+
bots.prev_file) _M="%s: created" ;;
|
|
530
|
+
bots.prev_tickets) _M="tickets: labels and ticket template on GitHub, tickets.yml workflow" ;;
|
|
531
|
+
bots.prev_app) _M="GitHub App: created in the browser, credentials stored as repository variable and secret" ;;
|
|
532
|
+
bots.prev_proteger) _M="GitHub settings: branch and tag rulesets, merge methods" ;;
|
|
533
|
+
bots.prev_npm) _M="npm: trusted publishing of the package, REPOWARDEN_NPM variable" ;;
|
|
534
|
+
bots.ask_confirm) _M="Apply?" ;;
|
|
535
|
+
bots.run_tickets) _M="Ticket tracking" ;;
|
|
536
|
+
bots.run_app) _M="GitHub App" ;;
|
|
537
|
+
bots.run_proteger) _M="Branch protection" ;;
|
|
538
|
+
bots.run_npm) _M="npm publishing" ;;
|
|
539
|
+
bots.failed_one) _M="%s: failed, see above; the other bots are set up. Run again: repowarden bots" ;;
|
|
540
|
+
bots.develop_created) _M="Branch %s created from %s." ;;
|
|
541
|
+
bots.conf_written) _M="%s updated." ;;
|
|
542
|
+
bots.kept) _M="%s exists: kept as is." ;;
|
|
543
|
+
bots.written) _M="%s written." ;;
|
|
544
|
+
bots.done) _M="Bots set up." ;;
|
|
545
|
+
bots.done_errors) _M="Bots set up, %s failed (see above)." ;;
|
|
546
|
+
bots.commit_files) _M="Files to commit through a PR (workflows act once on the default branch): git status" ;;
|
|
547
|
+
bots.verify) _M="Then: repowarden proteger --verifier, and repowarden statut." ;;
|
|
430
548
|
tk.reopened) _M="Reopened: closed by GitHub when #%s was merged into \`%s\`, which is not production yet. In pre-production; it will be closed at the release." ;;
|
|
431
549
|
tk.sync.ready) _M="Ticket #%s assigned: local branch %s ready (repowarden ticket %s)." ;;
|
|
432
550
|
tk.sync.not_validated) _M="Ticket #%s assigned but not validated yet: no branch for now." ;;
|
package/hooks/lib/i18n/fr.sh
CHANGED
|
@@ -100,6 +100,7 @@ _msg_fr() {
|
|
|
100
100
|
install.replaced) _M="core.hooksPath (%s) valait '%s', remplacé." ;;
|
|
101
101
|
install.enabled) _M="Hooks activés (%s) → %s" ;;
|
|
102
102
|
install.local_wins) _M="Un core.hooksPath local (ex. husky) reste prioritaire dans le dépôt concerné." ;;
|
|
103
|
+
install.bots_never) _M="Les bots du dépôt ne seront plus proposés (repowarden.bots = off) ; à la demande : repowarden bots" ;;
|
|
103
104
|
install.lang_set) _M="Langue des messages : français (changer : %s --global --lang en)" ;;
|
|
104
105
|
install.lang_invalid) _M="--lang : fr ou en." ;;
|
|
105
106
|
install.keys_migrated) _M="Réglages repogarde.* (%s) renommés en repowarden.*" ;;
|
|
@@ -232,6 +233,7 @@ _msg_fr() {
|
|
|
232
233
|
ci.check.16) _M="Cible « %s » conforme au flux." ;;
|
|
233
234
|
ci.check.17) _M="PR de « %s » vers « %s » : cible attendue %s (réglage integrationBranch)." ;;
|
|
234
235
|
ci.check.18) _M=" Corriger : modifier la branche de base de la PR (Edit, à côté du titre), ou gh pr edit --base %s" ;;
|
|
236
|
+
ci.check.develop_undeclared) _M="PR %s → %s : la branche develop existe mais .repowarden.conf ne déclare pas le flux develop → main. Ajouter integrationBranch = develop (le travail passe alors par develop), ou supprimer develop si le projet n'en veut pas." ;;
|
|
235
237
|
ci.check.19) _M="gitleaks absent : lancer ci/install-tool.sh gitleaks avant ce script." ;;
|
|
236
238
|
ci.check.20) _M="Dossier de travail modifié avant la vérification : impossible de contrôler le formatage." ;;
|
|
237
239
|
ci.check.21) _M="Un formateur a échoué (erreur de syntaxe, ou outil / dépendance indisponible) : voir le log ci-dessus." ;;
|
|
@@ -296,21 +298,57 @@ _msg_fr() {
|
|
|
296
298
|
ci.proteger.verify_ok) _M="Règles en ligne à jour." ;;
|
|
297
299
|
ci.proteger.delivery) _M=" livraison vers main : %s approbation(s) exigée(s) (passage à une nouvelle version) ; merge automatique des PR de travail vers develop : %s" ;;
|
|
298
300
|
ci.proteger.methods_flow) _M="main : merge commit ; %s : squash ou merge commit" ;;
|
|
301
|
+
ci.proteger.livraison_check) _M=" vérification « livraison » exigée sur la branche principale (préversion publiée, protection en place)" ;;
|
|
299
302
|
ci.proteger.tags_org) _M="réservés aux workflows" ;;
|
|
300
303
|
ci.proteger.tags_user) _M="ni déplacés ni supprimés (compte personnel : création libre)" ;;
|
|
301
304
|
ci.proteger.tags_none) _M="non protégés (--sans-tags)" ;;
|
|
302
305
|
ci.proteger.unknown_team) _M="Équipe inconnue ou inaccessible : %s (format @organisation/equipe)" ;;
|
|
303
306
|
ci.proteger.unknown_user) _M="Utilisateur inconnu : %s" ;;
|
|
307
|
+
mig.no_major) _M="Version majeure de repowarden introuvable (%s) : REPOWARDEN_MAJEURE=4 repowarden migrer." ;;
|
|
308
|
+
mig.dirty) _M="Modifications en cours : commiter ou remiser avant repowarden migrer --pr." ;;
|
|
309
|
+
mig.pr_open) _M="PR de migration déjà ouverte (%s) : rien à faire." ;;
|
|
310
|
+
mig.both) _M="%s et %s existent tous les deux : garder le second, fusionner puis supprimer le premier à la main." ;;
|
|
311
|
+
mig.conf) _M=".repogarde.conf → .repowarden.conf (section [repowarden], version à jour)" ;;
|
|
312
|
+
mig.dir) _M=".repogarde/ → .repowarden/" ;;
|
|
313
|
+
mig.workflow) _M="%s : uses: vers simdevWarden/repowarden, anciens noms remplacés" ;;
|
|
314
|
+
mig.renamed) _M="%s → %s" ;;
|
|
315
|
+
mig.tickets_events) _M="%s : événements du suivi des tickets complétés (push, revue, assignation, fermeture) : PR brouillon préremplie au premier push" ;;
|
|
316
|
+
mig.tickets_labels) _M="Étiquettes du suivi (type: feat, statuts…) : repowarden tickets init (relançable, ne réécrit aucun fichier)" ;;
|
|
317
|
+
mig.hooks_moved) _M="Hooks lefthook résiduels (%s) déplacés dans %s" ;;
|
|
318
|
+
mig.hooks_left) _M="Hooks lefthook résiduels dans .git/hooks (%s), ignorés : repowarden migrer --hooks pour les mettre de côté." ;;
|
|
319
|
+
mig.lefthook_conf) _M="%s : lefthook n'est plus pris en charge ; déplacer ses commandes dans .repowarden/<hook>, puis supprimer ce fichier." ;;
|
|
320
|
+
mig.secrets) _M="Secrets ou variables renommés dans les workflows, à recréer sous le nouveau nom (Settings → Secrets and variables) :%s" ;;
|
|
321
|
+
mig.remaining) _M="Citent encore repogarde (à relire, non modifiés) : %s" ;;
|
|
322
|
+
mig.nothing) _M="Rien à migrer : le projet utilise déjà les noms de repowarden." ;;
|
|
323
|
+
mig.next) _M="Ensuite : vérifier le diff, puis repowarden proteger (la vérification exigée s'appelle désormais repowarden)." ;;
|
|
324
|
+
mig.commit_subject) _M="passage de repogarde à repowarden v%s" ;;
|
|
325
|
+
mig.commit_body) _M="Anciens noms et chemins remplacés par repowarden migrer (docs/migration-v4.md) : les workflows réutilisables de l'ancien dépôt ne sont plus redirigés par GitHub." ;;
|
|
326
|
+
mig.pr_body) _M="Migration de repogarde vers repowarden, faite par repowarden migrer (docs/migration-v4.md)." ;;
|
|
327
|
+
mig.pr_after) _M="Après le merge : lancer repowarden proteger (la vérification exigée s'appelle désormais repowarden) et recréer sous leur nouveau nom les secrets REPOGARDE_* éventuels." ;;
|
|
328
|
+
mig.pr_created) _M="PR de migration ouverte (%s)." ;;
|
|
329
|
+
st.repo_migrate) _M="Anciens noms repogarde dans ce projet : repowarden migrer" ;;
|
|
330
|
+
st.repo_develop_undeclared) _M="La branche develop existe mais le flux develop → main n'est pas déclaré : ajouter integrationBranch = develop dans .repowarden.conf (sinon le travail peut entrer directement dans main)." ;;
|
|
304
331
|
ci.proteger.legacy_taken) _M="Ruleset « %s » : ancien ruleset « %s » repris (vérification repogarde retirée)." ;;
|
|
305
332
|
ci.proteger.legacy_left) _M="Ancien ruleset « %s » (id %s) : exige encore la vérification repogarde, retirée en v4, et bloque ses branches. Le supprimer : Settings → Rules → Rulesets, ou gh api -X DELETE repos/%s/rulesets/%s." ;;
|
|
306
333
|
ci.proteger.verify_legacy) _M="%s (id %s) : ancien ruleset, exige encore la vérification repogarde (retirée en v4)" ;;
|
|
307
334
|
ci.proteger.api_error) _M="Ruleset « %s » refusé par GitHub : %s" ;;
|
|
308
335
|
ci.proteger.incomplete) _M="Protection incomplète : voir les erreurs ci-dessus." ;;
|
|
309
|
-
ci.
|
|
336
|
+
ci.proteger.rulesets_unavailable) _M="Rulesets indisponibles pour %s : GitHub les refuse sur un dépôt privé d'un compte gratuit. Rendre le dépôt public, ou passer à GitHub Pro / Team ; les autres réglages sont appliqués." ;;
|
|
337
|
+
ci.proteger.tags_fallback) _M="Ruleset des tags : exception « GitHub Actions » refusée dans cette organisation ; tags protégés comme sur un compte personnel (ni déplacés ni supprimés, création libre)." ;;
|
|
338
|
+
ci.version.usage) _M="Usage : ci/version.sh next|notes|notes-livraison [ref]" ;;
|
|
310
339
|
ci.version.breaking) _M="Changements incompatibles" ;;
|
|
311
340
|
ci.version.features) _M="Fonctionnalités" ;;
|
|
312
341
|
ci.version.fixes) _M="Corrections" ;;
|
|
313
342
|
ci.version.maintenance) _M="Maintenance" ;;
|
|
343
|
+
ci.version.summary) _M="En bref" ;;
|
|
344
|
+
ci.version.todo) _M="À faire" ;;
|
|
345
|
+
ci.version.update) _M="Mettre à jour" ;;
|
|
346
|
+
ci.version.tickets) _M="Tickets livrés" ;;
|
|
347
|
+
ci.livraison.protection) _M="Protection du flux %s absente (merge commit, pas de suppression) : lancer repowarden proteger" ;;
|
|
348
|
+
ci.livraison.maintenance) _M="Maintenance seule : aucune version à publier" ;;
|
|
349
|
+
ci.livraison.non_exigee) _M="%s : préversion non exigée" ;;
|
|
350
|
+
ci.livraison.ok) _M="%s : préversion testée, livrable" ;;
|
|
351
|
+
ci.livraison.preversion) _M="%s : aucune préversion %s ; attendre celle du soir, ou Actions → release → Run workflow sur %s" ;;
|
|
314
352
|
ci.install_tool.os) _M="Système non supporté : %s" ;;
|
|
315
353
|
ci.install_tool.arch) _M="Architecture non supportée : %s" ;;
|
|
316
354
|
ci.install_tool.unknown) _M="Outil inconnu : %s" ;;
|
|
@@ -420,13 +458,93 @@ _msg_fr() {
|
|
|
420
458
|
app.server_failed) _M="Page locale non démarrée." ;;
|
|
421
459
|
app.open) _M="Ouvre %s puis clique sur le bouton vert de GitHub." ;;
|
|
422
460
|
app.no_code) _M="Aucune réponse de GitHub (création annulée, ou délai de 15 min dépassé)." ;;
|
|
423
|
-
app.created) _M="App %s créée ; identifiants rangés (variable
|
|
461
|
+
app.created) _M="App %s créée ; identifiants rangés (variable %s, secret %s)." ;;
|
|
424
462
|
app.step_install) _M="Installation sur le dépôt" ;;
|
|
425
463
|
app.installed) _M="App %s installée sur %s." ;;
|
|
426
464
|
app.not_installed) _M="App %s pas encore installée sur %s : relance repowarden app init une fois installée." ;;
|
|
427
465
|
app.check_in_ci) _M="Installation vérifiée au premier run du suivi des tickets (étape « Jeton de l'App ») ; pour l'installer : %s" ;;
|
|
428
466
|
app.done) _M="Les workflows repowarden utilisent désormais l'App : ce qu'ils font déclenche les autres workflows." ;;
|
|
429
467
|
app.next) _M="Sans l'App (variable et secret absents), ils reprennent le jeton des Actions." ;;
|
|
468
|
+
app.bot_all_repos) _M="Bot d'organisation : à l'installation, choisir « All repositories » (les nouveaux dépôts seront couverts d'office ; seuls ceux avec un .repowarden.conf sont gérés)." ;;
|
|
469
|
+
bot.init_exists) _M="%s existe déjà : laissé tel quel." ;;
|
|
470
|
+
bot.init_done) _M="%s écrit : passage chaque nuit, et à la demande (Actions → bot → Run workflow, case dry-run pour voir sans rien modifier)." ;;
|
|
471
|
+
bot.init_next) _M="Identifiants du bot dans ce dépôt : repowarden app init --bot (une fois, installée sur « All repositories »)." ;;
|
|
472
|
+
bot.no_report) _M="Rapport introuvable : %s" ;;
|
|
473
|
+
bot.report_updated) _M="Rapport publié (issue #%s mise à jour)." ;;
|
|
474
|
+
bot.report_created) _M="Rapport publié (nouvelle issue)." ;;
|
|
475
|
+
bot.col_repo) _M="Dépôt" ;;
|
|
476
|
+
bot.col_mode) _M="Mode" ;;
|
|
477
|
+
bot.col_protection) _M="Protection" ;;
|
|
478
|
+
bot.col_migration) _M="Migration" ;;
|
|
479
|
+
bot.repo) _M="%s" ;;
|
|
480
|
+
bot.not_adopted) _M="non adopté (pas de .repowarden.conf)" ;;
|
|
481
|
+
bot.ignored) _M="ignoré (bot = off)" ;;
|
|
482
|
+
bot.mode_invalid) _M="bot = %s : auto, pr ou off attendu" ;;
|
|
483
|
+
bot.clone_failed) _M="clone impossible : %s" ;;
|
|
484
|
+
bot.prot_ok) _M="à jour" ;;
|
|
485
|
+
bot.prot_stale) _M="⚠ périmée : repowarden proteger" ;;
|
|
486
|
+
bot.prot_applied) _M="✔ appliquée" ;;
|
|
487
|
+
bot.error) _M="✖ %s" ;;
|
|
488
|
+
bot.mig_none) _M="rien à migrer" ;;
|
|
489
|
+
bot.mig_open) _M="PR déjà ouverte" ;;
|
|
490
|
+
bot.mig_todo) _M="⚠ à migrer : repowarden migrer" ;;
|
|
491
|
+
bot.mig_pr) _M="✔ PR ouverte" ;;
|
|
492
|
+
bot.report_head) _M="Passage du %s." ;;
|
|
493
|
+
bot.report_dry) _M="Aperçu (dry-run) : rien n'a été modifié." ;;
|
|
494
|
+
bot.failed) _M="Passage terminé avec %s erreur(s) : voir le rapport." ;;
|
|
495
|
+
bots.skip) _M="Bots du dépôt non proposés (%s) : plus tard, repowarden bots" ;;
|
|
496
|
+
bots.why_repo) _M="hors d'un dépôt Git" ;;
|
|
497
|
+
bots.why_github) _M="dépôt hors de GitHub" ;;
|
|
498
|
+
bots.why_gh) _M="gh absent : https://cli.github.com" ;;
|
|
499
|
+
bots.why_gh_login) _M="gh non connecté : gh auth login" ;;
|
|
500
|
+
bots.why_admin) _M="droits d'administration du dépôt nécessaires" ;;
|
|
501
|
+
bots.why_tty) _M="pas de terminal pour répondre aux questions" ;;
|
|
502
|
+
bots.ask_global) _M="Configurer les bots de ce dépôt (CI, releases, tickets, protection…) ? Rien n'est fait sans ton accord, bot par bot." ;;
|
|
503
|
+
bots.later) _M="Aucun bot configuré. Plus tard : repowarden bots" ;;
|
|
504
|
+
bots.flow_question) _M="Flux des branches :" ;;
|
|
505
|
+
bots.flow_main) _M="%s seule : chaque PR y est mergée (squash)" ;;
|
|
506
|
+
bots.flow_develop) _M="develop → %s : le travail s'intègre dans develop (préversions), seul develop entre dans %s (livraison)" ;;
|
|
507
|
+
bots.ask_create_develop) _M="La branche develop n'existe pas sur GitHub : la créer depuis la branche par défaut ?" ;;
|
|
508
|
+
bots.one_by_one) _M="Un accord par bot (Entrée : oui) :" ;;
|
|
509
|
+
bots.app_present) _M="GitHub App des workflows déjà configurée : utilisée par les autres bots." ;;
|
|
510
|
+
bots.desc_ci) _M=" CI : vérifie chaque PR (messages, branche, secrets, formatage, tests) ; écrit .github/workflows/repowarden.yml" ;;
|
|
511
|
+
bots.desc_release) _M=" Releases : version, notes et tag calculés depuis les commits ; écrit .github/workflows/release.yml" ;;
|
|
512
|
+
bots.desc_nettoyage) _M=" Nettoyage : supprime les branches mergées, garde les branches longues ; écrit .github/workflows/nettoyage.yml" ;;
|
|
513
|
+
bots.desc_tickets) _M=" Tickets : le ticket d'abord, PR préremplie, statuts jusqu'à la production ; étiquettes, modèle de ticket, workflow (repowarden tickets init)" ;;
|
|
514
|
+
bots.desc_app) _M=" GitHub App : ce que font les bots déclenche les autres workflows ; création dans le navigateur (repowarden app init)" ;;
|
|
515
|
+
bots.desc_proteger) _M=" Protection : PR et vérification exigées, ni suppression ni push forcé ; modifie les réglages GitHub (repowarden proteger)" ;;
|
|
516
|
+
bots.desc_npm) _M=" npm : publie le paquet à chaque release, sans jeton (repowarden npm-publication)" ;;
|
|
517
|
+
bots.ask_ci) _M="CI ?" ;;
|
|
518
|
+
bots.ask_release) _M="Releases ?" ;;
|
|
519
|
+
bots.ask_nettoyage) _M="Nettoyage des branches ?" ;;
|
|
520
|
+
bots.ask_tickets) _M="Suivi des tickets ?" ;;
|
|
521
|
+
bots.ask_app) _M="GitHub App ?" ;;
|
|
522
|
+
bots.ask_proteger) _M="Protection des branches ?" ;;
|
|
523
|
+
bots.ask_npm) _M="Publication npm ?" ;;
|
|
524
|
+
bots.preview) _M="Aperçu" ;;
|
|
525
|
+
bots.prev_develop) _M="branche %s créée sur GitHub depuis %s" ;;
|
|
526
|
+
bots.prev_conf) _M=".repowarden.conf : integrationBranch = %s, branches protégées" ;;
|
|
527
|
+
bots.prev_review) _M=".repowarden.conf : livraison validée par la revue de sa PR (sans GitHub App)" ;;
|
|
528
|
+
bots.prev_kept) _M="%s existe : gardé tel quel (écart avec le modèle : %s ligne(s))" ;;
|
|
529
|
+
bots.prev_file) _M="%s : créé" ;;
|
|
530
|
+
bots.prev_tickets) _M="tickets : étiquettes et modèle de ticket sur GitHub, workflow tickets.yml" ;;
|
|
531
|
+
bots.prev_app) _M="GitHub App : créée dans le navigateur, identifiants rangés en variable et secret du dépôt" ;;
|
|
532
|
+
bots.prev_proteger) _M="réglages GitHub : rulesets des branches et des tags, modes de merge" ;;
|
|
533
|
+
bots.prev_npm) _M="npm : publication de confiance du paquet, variable REPOWARDEN_NPM" ;;
|
|
534
|
+
bots.ask_confirm) _M="Appliquer ?" ;;
|
|
535
|
+
bots.run_tickets) _M="Suivi des tickets" ;;
|
|
536
|
+
bots.run_app) _M="GitHub App" ;;
|
|
537
|
+
bots.run_proteger) _M="Protection des branches" ;;
|
|
538
|
+
bots.run_npm) _M="Publication npm" ;;
|
|
539
|
+
bots.failed_one) _M="%s : échec, voir ci-dessus ; les autres bots sont configurés. Relancer : repowarden bots" ;;
|
|
540
|
+
bots.develop_created) _M="Branche %s créée depuis %s." ;;
|
|
541
|
+
bots.conf_written) _M="%s mis à jour." ;;
|
|
542
|
+
bots.kept) _M="%s existe : gardé tel quel." ;;
|
|
543
|
+
bots.written) _M="%s écrit." ;;
|
|
544
|
+
bots.done) _M="Bots configurés." ;;
|
|
545
|
+
bots.done_errors) _M="Bots configurés, %s en échec (voir ci-dessus)." ;;
|
|
546
|
+
bots.commit_files) _M="Fichiers à commiter par une PR (les workflows agissent une fois sur la branche par défaut) : git status" ;;
|
|
547
|
+
bots.verify) _M="Ensuite : repowarden proteger --verifier, et repowarden statut." ;;
|
|
430
548
|
tk.reopened) _M="Rouvert : fermé par GitHub au merge de #%s dans \`%s\`, ce n'est pas encore la production. En préprod ; il sera fermé à la release." ;;
|
|
431
549
|
tk.sync.ready) _M="Ticket #%s assigné : branche locale %s prête (repowarden ticket %s)." ;;
|
|
432
550
|
tk.sync.not_validated) _M="Ticket #%s assigné mais pas encore validé : pas de branche pour l'instant." ;;
|
package/install.sh
CHANGED
|
@@ -4,6 +4,9 @@
|
|
|
4
4
|
# ./install.sh --global active les hooks pour tous les dépôts
|
|
5
5
|
# (et l'assistant de commit : git cc)
|
|
6
6
|
# ./install.sh --global --lang en langue des messages (fr, en) ; demandée une fois sinon
|
|
7
|
+
# ./install.sh --bots propose ensuite les bots du dépôt GitHub (repowarden bots) ;
|
|
8
|
+
# proposés d'office dans un dépôt GitHub, avec un terminal
|
|
9
|
+
# ./install.sh --sans-bots ne plus jamais les proposer
|
|
7
10
|
# ./install.sh --uninstall [--global]
|
|
8
11
|
# retire les hooks (seulement s'ils sont ceux de repowarden)
|
|
9
12
|
# ./install.sh --uninstall --global --purge [--scan DOSSIER]
|
|
@@ -22,12 +25,15 @@ ACTION="install"
|
|
|
22
25
|
PURGE=""
|
|
23
26
|
SCAN=""
|
|
24
27
|
LANG_CHOICE=""
|
|
28
|
+
BOTS=""
|
|
25
29
|
|
|
26
30
|
while [ $# -gt 0 ]; do
|
|
27
31
|
case "$1" in
|
|
28
32
|
--global) SCOPE="--global" ;;
|
|
29
33
|
--uninstall) ACTION="uninstall" ;;
|
|
30
34
|
--purge) PURGE=1 ;;
|
|
35
|
+
--bots) BOTS=demande ;;
|
|
36
|
+
--sans-bots) BOTS=jamais ;;
|
|
31
37
|
--lang)
|
|
32
38
|
shift
|
|
33
39
|
LANG_CHOICE="${1:-}"
|
|
@@ -37,7 +43,7 @@ while [ $# -gt 0 ]; do
|
|
|
37
43
|
SCAN="${1:?--scan attend un dossier}"
|
|
38
44
|
;;
|
|
39
45
|
-h | --help)
|
|
40
|
-
sed -n '2,
|
|
46
|
+
sed -n '2,14p' "$0" | sed 's/^# \{0,1\}//'
|
|
41
47
|
exit 0
|
|
42
48
|
;;
|
|
43
49
|
*)
|
|
@@ -243,3 +249,15 @@ if [ "$SCOPE" = --global ]; then
|
|
|
243
249
|
t install.local_wins
|
|
244
250
|
info "$REPLY"
|
|
245
251
|
fi
|
|
252
|
+
|
|
253
|
+
# Bots du dépôt GitHub courant (CI, releases, tickets, protection…) : proposés,
|
|
254
|
+
# jamais configurés sans accord ; --sans-bots : plus jamais proposés
|
|
255
|
+
case "$BOTS" in
|
|
256
|
+
jamais)
|
|
257
|
+
git config "$SCOPE" repowarden.bots off
|
|
258
|
+
t install.bots_never
|
|
259
|
+
info "$REPLY"
|
|
260
|
+
;;
|
|
261
|
+
demande) bash "$ROOT/bin/bots" ;;
|
|
262
|
+
*) ! git rev-parse --git-dir >/dev/null 2>&1 || bash "$ROOT/bin/bots" --depuis-install || true ;;
|
|
263
|
+
esac
|
package/package.json
CHANGED