From 697087f593dae0163e01becf483b192894e69e33 Mon Sep 17 00:00:00 2001 From: vdbe <44153531+vdbe@users.noreply.github.com> Date: Sun, 12 May 2024 16:34:44 +0000 Subject: [PATCH] Fix/test old bash (#216) * test(old-bash): use tmux instead of mocking it * quote output --- .github/scripts/test.bash | 2 +- .github/workflows/test.yml | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/scripts/test.bash b/.github/scripts/test.bash index d1df7e5..bfe9c32 100755 --- a/.github/scripts/test.bash +++ b/.github/scripts/test.bash @@ -59,7 +59,7 @@ main() { exit 1 else echo "Running plugin: $plugin" >&2 - output=$(tmux run-shell "$plugin" 2>&1) + output="$(tmux run-shell "$plugin" 2>&1)" exit_code="$?" check "$exit_code" "$output" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7b85e57..2365de7 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -38,16 +38,14 @@ jobs: name: "Old Bash" runs-on: ubuntu-latest container: - image: bash:3.2.57 # Bash version used by macos + image: bash:3.2.57-alpine3.19 # Bash version used by macos steps: - uses: actions/checkout@v4 - name: Check Syntax is Valid shell: bash run: | - # No tmux available in this container - tmp="$(mktemp -d)" - touch "$tmp/tmux" - chmod +x "$tmp/tmux" - export PATH="$tmp:$PATH" + apk update + apk add tmux bash --version + tmux -V ./.github/scripts/test.bash ./catppuccin.tmux