History

Use bash for everything on all platforms in release workflow

The way environment variables are being set and accessed assumes a Bourne-style (POSIX-like) shell, but PowerShell was being used on Windows for some steps where this was being assumed. It's possible to set bash only for some steps, but that is more complex to understand than using it for everything.

Eliah Kagan committed 2 years ago

Commit edd1c431 parent 55cffe41 file · +10 −7Browse files

Unified · Split

.github/workflows/release.yml+10−7
@@ -12,11 +12,6 @@ · 11 unmodified lines
1212
1313 name: release
1414
15−env:
16− RUST_BACKTRACE: 1
17− CARGO_TERM_COLOR: always
18− CLICOLOR: 1
19−
2015 on:
2116 workflow_dispatch:
2217 push:
@@ -25,6 +20,16 @@ on: · 2 unmodified lines
2520 # - fix-releases
2621 tags:
2722 - "v.*"
23+
24+env:
25+ RUST_BACKTRACE: 1
26+ CARGO_TERM_COLOR: always
27+ CLICOLOR: 1
28+
29+defaults:
30+ run:
31+ shell: bash
32+
2833 jobs:
2934 create-release:
3035 name: create-release
@@ -167,7 +172,6 @@ jobs: · 136 unmodified lines
167172 path: artifacts
168173
169174 - name: Set release upload URL and release version
170− shell: bash
171175 run: |
172176 release_upload_url="$(cat artifacts/release-upload-url)"
173177 echo "RELEASE_UPLOAD_URL=$release_upload_url" >> $GITHUB_ENV
@@ -193,7 +197,6 @@ jobs: · 19 unmodified lines
193197 /target/arm-unknown-linux-gnueabihf/release/${{ env.EXE_NAME }} \
194198 /target/arm-unknown-linux-gnueabihf/release/gix
195199 - name: Build archive
196− shell: bash
197200 run: |
198201 staging="gitoxide-${{ matrix.feature }}-${{ env.RELEASE_VERSION }}-${{ matrix.target }}"
199202 mkdir -p "$staging"