From 15c6cc7e16f5d5357b73209f42650decc29ea3a8 Mon Sep 17 00:00:00 2001 From: Agent Date: Thu, 16 Apr 2026 17:57:59 +0000 Subject: [PATCH] fix: Replace UTF-8 em-dash with ASCII hyphen in CLI output and tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace em-dash (—) with ASCII hyphen (-) in: - bin/disinto: 'Dry run complete' message - bin/disinto: import skip message - lib/init/nomad/cluster-up.sh: 'Dry run complete' message - tests/disinto-init-nomad.bats: test assertions This fixes CI failures caused by bats test runner not handling UTF-8 em-dash characters correctly. --- bin/disinto | 6 +++--- lib/init/nomad/cluster-up.sh | 2 +- tests/disinto-init-nomad.bats | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/bin/disinto b/bin/disinto index 634d627..b86249f 100755 --- a/bin/disinto +++ b/bin/disinto @@ -723,7 +723,7 @@ _disinto_init_nomad() { echo "[auth] [dry-run] ${vault_auth_sh}" echo "" else - echo "[import] no --import-env/--import-sops — skipping; set them or seed kv/disinto/* manually before deploying secret-dependent services" + echo "[import] no --import-env/--import-sops - skipping; set them or seed kv/disinto/* manually before deploying secret-dependent services" echo "" fi @@ -818,7 +818,7 @@ _disinto_init_nomad() { sudo -n -- "${import_cmd[@]}" || exit $? fi else - echo "[import] no --import-env/--import-sops — skipping; set them or seed kv/disinto/* manually before deploying secret-dependent services" + echo "[import] no --import-env/--import-sops - skipping; set them or seed kv/disinto/* manually before deploying secret-dependent services" fi # Deploy services if requested @@ -1134,7 +1134,7 @@ p.write_text(text) echo "[ensure] CLAUDE_CONFIG_DIR" echo "[ensure] state files (.dev-active, .reviewer-active, .gardener-active)" echo "" - echo "Dry run complete — no changes made." + echo "Dry run complete - no changes made." exit 0 fi diff --git a/lib/init/nomad/cluster-up.sh b/lib/init/nomad/cluster-up.sh index 4aab42d..84a6e9c 100755 --- a/lib/init/nomad/cluster-up.sh +++ b/lib/init/nomad/cluster-up.sh @@ -135,7 +135,7 @@ EOF → export VAULT_ADDR=${VAULT_ADDR_DEFAULT} → export NOMAD_ADDR=${NOMAD_ADDR_DEFAULT} -Dry run complete — no changes made. +Dry run complete - no changes made. EOF exit 0 fi diff --git a/tests/disinto-init-nomad.bats b/tests/disinto-init-nomad.bats index 9765a23..75bb884 100644 --- a/tests/disinto-init-nomad.bats +++ b/tests/disinto-init-nomad.bats @@ -44,7 +44,7 @@ setup_file() { [[ "$output" == *"[dry-run] Step 8/9: systemctl start nomad + poll until ≥1 node ready"* ]] [[ "$output" == *"[dry-run] Step 9/9: write /etc/profile.d/disinto-nomad.sh"* ]] - [[ "$output" == *"Dry run complete — no changes made."* ]] + [[ "$output" == *"Dry run complete - no changes made."* ]] } # ── --backend=nomad --empty --dry-run ──────────────────────────────────────── @@ -58,7 +58,7 @@ setup_file() { # both modes invoke the same cluster-up dry-run. [[ "$output" == *"nomad backend: --empty (cluster-up only, no jobs)"* ]] [[ "$output" == *"[dry-run] Step 1/9: install nomad + vault binaries + docker daemon"* ]] - [[ "$output" == *"Dry run complete — no changes made."* ]] + [[ "$output" == *"Dry run complete - no changes made."* ]] } # ── --backend=docker (regression guard) ────────────────────────────────────── @@ -238,7 +238,7 @@ setup_file() { @test "disinto init --backend=nomad without import flags shows skip message" { run "$DISINTO_BIN" init placeholder/repo --backend=nomad --dry-run [ "$status" -eq 0 ] - [[ "$output" == *"no --import-env/--import-sops — skipping"* ]] + [[ "$output" == *"no --import-env/--import-sops - skipping"* ]] } @test "disinto init --backend=nomad --import-env --import-sops --age-key --with forgejo --dry-run shows all plans" {