Skip to content

Commit

Permalink
Simplify testing.
Browse files Browse the repository at this point in the history
  • Loading branch information
Paebbels committed Jan 16, 2025
1 parent 33cadaa commit 5a3a276
Showing 1 changed file with 22 additions and 12 deletions.
34 changes: 22 additions & 12 deletions .github/workflows/Pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,16 @@ jobs:
shell: bash

steps:
- name: Detect correct shell
id: detect
run: |
# Detect correct shell
if [[ "${{ matrix.name }}" == "Windows" && "${{ matrix.runtime }}" != "" ]]; then
printf "shell=msys2 {0}" >> $GITHUB_OUTPUT
else
printf "shell=bash" >> $GITHUB_OUTPUT
fi
- name: 🟦 Setup MSYS2 for ${{ matrix.runtime }}
uses: msys2/setup-msys2@v2
if: matrix.runtime != ''
Expand All @@ -66,24 +76,24 @@ jobs:
runtime: ${{ matrix.runtime }}
investigate: true

- name: Verify on Linux or macOS
if: matrix.name == 'Ubuntu' || matrix.name == 'macOS'
- name: Verify on Linux, macOS and Windows (native)
if: matrix.name == 'Linux' || matrix.name == 'macOS' || ( matrix.name == 'Windows' && matrix.runtime == '' )
run: |
printf "%s\n" "${PATH}"
printf "which ghdl: %s\n" "$(which ghdl)"
which ghdl
ghdl --version
- name: Verify on Windows (native)
if: matrix.name == 'Windows' && matrix.runtime == ''
shell: powershell
- name: Verify on Linux, macOS and Windows (native)
if: matrix.name == 'Windows' && matrix.runtime != ''
shell: "msys {0}"
run: |
echo $(Get-Command ghdl).Source
printf "which ghdl: %s\n" "$(which ghdl)"
ghdl --version
- name: Verify on Windows + MSYS2
if: matrix.name == 'Windows' && matrix.runtime != ''
shell: 'msys2 {0}'
- name: Verify on Windows (native) with Powershell
if: matrix.name == 'Windows' && matrix.runtime == ''
shell: powershell
run: |
which ghdl
echo $(Get-Command ghdl).Source
ghdl --version

0 comments on commit 5a3a276

Please sign in to comment.