Skip to content

Commit 123201e

Browse files
authored
Avoid repeatedly specifying bash as the command shell in CI (#1926)
1 parent 422e8ee commit 123201e

File tree

4 files changed

+5
-25
lines changed

4 files changed

+5
-25
lines changed

.github/workflows/analysis.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ jobs:
1010
- name: Checkout repo
1111
uses: actions/checkout@v6
1212
- name: Install deps
13-
shell: bash
1413
run: |
1514
./.github/scripts/install_deps.sh ubuntu-latest
1615
- name: Static analysis

.github/workflows/coverage.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,12 @@ jobs:
1010
- name: Checkout repo
1111
uses: actions/checkout@v6
1212
- name: Install deps
13-
shell: bash
1413
run: |
1514
./.github/scripts/install_deps.sh ubuntu
1615
- name: Install LCOV
1716
run: |
1817
sudo apt-get install lcov
1918
- name: Install test dependency dependencies
20-
shell: bash
2119
run: |
2220
test/fetch-test-deps.sh --get-deps ubuntu
2321
- name: Generate coverage report

.github/workflows/create-release-artifacts.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ jobs:
3232
run: |
3333
bash .github/scripts/install_deps.sh windows
3434
- name: Build Windows binaries
35-
shell: bash
3635
run: |
3736
cmake -S . -B build --preset msvc${{ matrix.bits }} -DFETCHCONTENT_BASE_DIR="${{ env.DEPS_ROOT_DIR }}"
3837
cmake --build build --config Release
@@ -53,7 +52,6 @@ jobs:
5352
- name: Checkout repo
5453
uses: actions/checkout@v6
5554
- name: Install deps
56-
shell: bash
5755
run: |
5856
./.github/scripts/install_deps.sh macos
5957
- name: Build libpng
@@ -80,7 +78,6 @@ jobs:
8078
- name: Checkout repo
8179
uses: actions/checkout@v6
8280
- name: Install deps
83-
shell: bash
8481
run: |
8582
./.github/scripts/install_deps.sh ubuntu-22.04
8683
- name: Build binaries

.github/workflows/testing.yml

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@ env:
2020
# otherwise they can trigger `-Werror=dev` (from the `develop` preset).
2121
DEPS_ROOT_DIR: ~/_deps # Note that this needs to be used in a position where Bash will trigger tilde expansion!
2222

23+
# We use bash syntax across OSes for consistency unless otherwise specified
24+
defaults:
25+
run:
26+
shell: bash
27+
2328
jobs:
2429
unix:
2530
strategy:
@@ -35,7 +40,6 @@ jobs:
3540
- name: Checkout repo
3641
uses: actions/checkout@v6
3742
- name: Install deps
38-
shell: bash
3943
run: |
4044
./.github/scripts/install_deps.sh ${{ matrix.os }}
4145
- name: Build & install using Make
@@ -66,7 +70,6 @@ jobs:
6670
if-no-files-found: error
6771
- name: Compute test dependency cache params
6872
id: test-deps-cache-params
69-
shell: bash
7073
run: |
7174
paths=$(test/fetch-test-deps.sh --get-paths)
7275
hash=$(test/fetch-test-deps.sh --get-hash)
@@ -84,12 +87,10 @@ jobs:
8487
run: |
8588
test/fetch-test-deps.sh
8689
- name: Install test dependency dependencies
87-
shell: bash
8890
run: |
8991
test/fetch-test-deps.sh --get-deps ${{ matrix.os }}
9092
- name: Run tests using our script
9193
if: matrix.buildsys == 'make'
92-
shell: bash
9394
run: |
9495
CXX=${{ matrix.cxx }} test/run-tests.sh --os ${{ matrix.os }}
9596
- name: Run tests using CTest
@@ -103,7 +104,6 @@ jobs:
103104
- name: Checkout repo
104105
uses: actions/checkout@v6
105106
- name: Install deps
106-
shell: bash
107107
run: |
108108
./.github/scripts/install_deps.sh macos
109109
- name: Build libpng
@@ -124,7 +124,6 @@ jobs:
124124
if-no-files-found: error
125125
- name: Compute test dependency cache params
126126
id: test-deps-cache-params
127-
shell: bash
128127
run: |
129128
paths=$(test/fetch-test-deps.sh --get-paths)
130129
hash=$(test/fetch-test-deps.sh --get-hash)
@@ -142,11 +141,9 @@ jobs:
142141
run: |
143142
test/fetch-test-deps.sh
144143
- name: Install test dependency dependencies
145-
shell: bash
146144
run: |
147145
test/fetch-test-deps.sh --get-deps macos
148146
- name: Run tests
149-
shell: bash
150147
run: |
151148
test/run-tests.sh --os macos
152149
@@ -175,7 +172,6 @@ jobs:
175172
cmake --build build
176173
- name: Package binaries
177174
working-directory: build
178-
shell: bash
179175
run: |
180176
cpack -DCPACK_PACKAGE_FILE_NAME=rgbds-win${{ matrix.bits }} -G ZIP -C Debug --verbose
181177
- name: Upload Windows binaries
@@ -186,7 +182,6 @@ jobs:
186182
if-no-files-found: error
187183
- name: Compute test dependency cache params
188184
id: test-deps-cache-params
189-
shell: bash
190185
run: |
191186
paths=$(test/fetch-test-deps.sh --get-paths)
192187
hash=$(test/fetch-test-deps.sh --get-hash)
@@ -200,16 +195,13 @@ jobs:
200195
key: ${{ matrix.os }}-${{ matrix.bits }}-${{ steps.test-deps-cache-params.outputs.hash }}
201196
- name: Fetch test dependency repositories
202197
if: steps.test-deps-cache.outputs.cache-hit != 'true'
203-
shell: bash
204198
continue-on-error: true
205199
run: |
206200
test/fetch-test-deps.sh
207201
- name: Install test dependency dependencies
208-
shell: bash
209202
run: |
210203
test/fetch-test-deps.sh --get-deps ${{ matrix.os }}
211204
- name: Run tests
212-
shell: bash
213205
run: |
214206
test/run-tests.sh --os ${{ matrix.os }}
215207
@@ -232,7 +224,6 @@ jobs:
232224
- name: Checkout repo
233225
uses: actions/checkout@v6
234226
- name: Install deps
235-
shell: bash
236227
run: |
237228
./.github/scripts/install_deps.sh ubuntu
238229
- name: Install MinGW
@@ -289,13 +280,11 @@ jobs:
289280
name: testing-programs-mingw-win${{ matrix.bits }}
290281
path: test/gfx
291282
- name: Extract binaries
292-
shell: bash
293283
run: |
294284
cp bins/* .
295285
cp bins/*.dll test/gfx
296286
- name: Compute test dependency cache params
297287
id: test-deps-cache-params
298-
shell: bash
299288
run: |
300289
paths=$(test/fetch-test-deps.sh --get-paths)
301290
hash=$(test/fetch-test-deps.sh --get-hash)
@@ -309,16 +298,13 @@ jobs:
309298
key: mingw-${{ matrix.bits }}-${{ steps.test-deps-cache-params.outputs.hash }}
310299
- name: Fetch test dependency repositories
311300
if: steps.test-deps-cache.outputs.cache-hit != 'true'
312-
shell: bash
313301
continue-on-error: true
314302
run: |
315303
test/fetch-test-deps.sh
316304
- name: Install test dependency dependencies
317-
shell: bash
318305
run: |
319306
test/fetch-test-deps.sh --get-deps ${{ matrix.os }}
320307
- name: Run tests
321-
shell: bash
322308
run: |
323309
test/run-tests.sh --os ${{ matrix.os }}
324310

0 commit comments

Comments
 (0)