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
12 12
13name: release13name: release
14 14
15env:
16 RUST_BACKTRACE: 1
17 CARGO_TERM_COLOR: always
18 CLICOLOR: 1
19
20on:15on:
21 workflow_dispatch:16 workflow_dispatch:
22 push:17 push:
@@ -25,6 +20,16 @@ on: · 2 unmodified lines
25 # - fix-releases20 # - fix-releases
26 tags:21 tags:
27 - "v.*"22 - "v.*"
23
24env:
25 RUST_BACKTRACE: 1
26 CARGO_TERM_COLOR: always
27 CLICOLOR: 1
28
29defaults:
30 run:
31 shell: bash
32
28jobs:33jobs:
29 create-release:34 create-release:
30 name: create-release35 name: create-release
@@ -167,7 +172,6 @@ jobs: · 136 unmodified lines
167 path: artifacts172 path: artifacts
168 173
169 - name: Set release upload URL and release version174 - name: Set release upload URL and release version
170 shell: bash
171 run: |175 run: |
172 release_upload_url="$(cat artifacts/release-upload-url)"176 release_upload_url="$(cat artifacts/release-upload-url)"
173 echo "RELEASE_UPLOAD_URL=$release_upload_url" >> $GITHUB_ENV177 echo "RELEASE_UPLOAD_URL=$release_upload_url" >> $GITHUB_ENV
@@ -193,7 +197,6 @@ jobs: · 19 unmodified lines
193 /target/arm-unknown-linux-gnueabihf/release/${{ env.EXE_NAME }} \197 /target/arm-unknown-linux-gnueabihf/release/${{ env.EXE_NAME }} \
194 /target/arm-unknown-linux-gnueabihf/release/gix198 /target/arm-unknown-linux-gnueabihf/release/gix
195 - name: Build archive199 - name: Build archive
196 shell: bash
197 run: |200 run: |
198 staging="gitoxide-${{ matrix.feature }}-${{ env.RELEASE_VERSION }}-${{ matrix.target }}"201 staging="gitoxide-${{ matrix.feature }}-${{ env.RELEASE_VERSION }}-${{ matrix.target }}"
199 mkdir -p "$staging"202 mkdir -p "$staging"