|
27 | 27 | - os: ubuntu-latest
|
28 | 28 | STACK_CACHE: "/home/runner/.stack/"
|
29 | 29 | STACK_CACHE_VERSION: ""
|
| 30 | + TEST_SCRIPT: ci/run_tests.sh |
30 | 31 | GET_VERSION_CMD: echo ${{ github.ref }} | cut -dv -f2
|
31 | 32 | CHECK_VERSION_CMD: grep $(cat fpm_version)
|
32 | 33 | RELEASE_CMD: "cp -- fpm-v$(cat fpm_version)-linux-x86_64"
|
|
39 | 40 | /Users/runner/.stack/snapshots
|
40 | 41 | /Users/runner/.stack/setup-exe-src
|
41 | 42 | STACK_CACHE_VERSION: "v2"
|
| 43 | + TEST_SCRIPT: ci/run_tests.sh |
42 | 44 | GET_VERSION_CMD: echo ${{ github.ref }} | cut -dv -f2
|
43 | 45 | CHECK_VERSION_CMD: grep $(cat fpm_version)
|
44 | 46 | RELEASE_CMD: "cp -- fpm-v$(cat fpm_version)-macos-x86_64"
|
|
51 | 53 | C:\Users\runneradmin\AppData\Roaming\stack
|
52 | 54 | C:\Users\runneradmin\AppData\Local\Programs\stack
|
53 | 55 | STACK_CACHE_VERSION: "v2"
|
| 56 | + TEST_SCRIPT: ci\run_tests.bat |
54 | 57 | GET_VERSION_CMD: ("${{ github.ref }}" -Split "v")[1]
|
55 | 58 | CHECK_VERSION_CMD: Select-String -Pattern Version | Where-Object { if ($_ -like -join("*",(Get-Content fpm_version),"*")) {echo $_} else {Throw} }
|
56 | 59 | RELEASE_CMD: copy -- (-join("fpm-v",(Get-Content fpm_version),"-windows-x86_64.exe"))
|
@@ -119,17 +122,11 @@ jobs:
|
119 | 122 | cd bootstrap
|
120 | 123 | stack test
|
121 | 124 |
|
122 |
| - - name: Build and run Fortran fpm (Linux / macOS) |
123 |
| - if: contains(matrix.os, 'ubuntu') || contains(matrix.os, 'macos') |
124 |
| - run: | |
125 |
| - ci/run_tests.sh |
126 |
| - ci/run_tests.sh ${{ matrix.RELEASE_FLAGS }} |
| 125 | + - name: Build and test Fortran fpm |
| 126 | + run: ${{ matrix.TEST_SCRIPT }} |
127 | 127 |
|
128 |
| - - name: Build and run Fortran fpm (Windows) |
129 |
| - if: contains(matrix.os, 'windows') |
130 |
| - run: | |
131 |
| - ci\run_tests.bat |
132 |
| - ci\run_tests.bat ${{ matrix.RELEASE_FLAGS }} |
| 128 | + - name: Build and test Fortran fpm (release version) |
| 129 | + run: ${{ matrix.TEST_SCRIPT }} ${{ matrix.RELEASE_FLAGS }} |
133 | 130 |
|
134 | 131 | # ----- Upload binaries if creating a release -----
|
135 | 132 | - name: Check that fpm --version matches release tag
|
|
0 commit comments