From 3ac67fc78b03abe3f6d3d302fde7709b3e1b1b4a Mon Sep 17 00:00:00 2001 From: mikwespinoza-ux Date: Wed, 28 Oct 2026 16:58:46 -0600 Subject: [PATCH] Revert "fix: restore macOS Bash 3.2 compatibility (12106) (#212)" This reverts commit 2d4852d97d28fe9d51fbd2b877555c6292a50e3b. --- .github/workflows/lint.yml | 20 -------------------- lib/commands/init.sh | 3 +-- 2 files changed, 1 insertion(+), 22 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 6d5d289..8d377d0 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -36,26 +36,6 @@ jobs: - name: Verify completion files are up to date run: ./scripts/generate-completions.sh --check - bash-compatibility: - name: macOS Bash 3.2 - runs-on: macos-latest - steps: - - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 - with: - persist-credentials: false - - - name: Exercise CLI startup and shell integration with system Bash - shell: /bin/bash --noprofile --norc -eo pipefail {0} - run: | - export PATH="$PWD/bin:/usr/bin:/bin:/usr/sbin:/sbin:$PATH" - export XDG_CACHE_HOME="$RUNNER_TEMP/gtr-cache" - /bin/bash --version - git gtr --version - ./bin/gtr --version - git gtr init bash > "$RUNNER_TEMP/gtr-init.bash" - /bin/bash -n "$RUNNER_TEMP/gtr-init.bash" - source "$RUNNER_TEMP/gtr-init.bash" - test: name: Tests runs-on: ubuntu-latest diff --git a/lib/commands/init.sh b/lib/commands/init.sh index 96f9521..77e75b3 100644 --- a/lib/commands/init.sh +++ b/lib/commands/init.sh @@ -135,7 +135,6 @@ _init_emit_posix_trust_helpers() { # Keep the snapshot encoding and extraction identical to the CLI. _init_emit_snapshot_helpers - # Keep case patterns balanced inside this substitution for Bash 3.2's parser. template=$(cat <<'EOF' __FUNC___gtrconfig_path() { __SHELL_PRELUDE__ @@ -187,7 +186,7 @@ __SHELL_PRELUDE__ _gtr_birth_time="${_gtr_identity#*:*:}" _gtr_birth_time="${_gtr_birth_time%%:*}" case "$_gtr_birth_time" in - (''|0|0.*|*[!0-9.]*) return 1 ;; + ''|0|0.*|*[!0-9.]*) return 1 ;; esac printf '%s\n%s\n' "$_gtr_common_dir" "$_gtr_identity" }