Skip to content

Commit 40ea346

Browse files
committed
changed sha command for mac to the more likely to be present shasum
1 parent 92dedd3 commit 40ea346

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,14 +78,22 @@ jobs:
7878
if: matrix.os != 'windows-latest'
7979
run: strip target/${{ matrix.target }}/release/${{ matrix.artifact_name }}
8080

81-
- name: Generate checksum (Linux/macOS)
82-
if: matrix.os != 'windows-latest'
81+
- name: Generate checksum (Linux)
82+
if: matrix.os == 'ubuntu-latest'
8383
run: |
8484
artifact_path="target/${{ matrix.target }}/release/${{ matrix.artifact_name }}"
8585
checksum_path="target/${{ matrix.target }}/release/${{ matrix.asset_name }}.sha256"
8686
hash="$(sha256sum "$artifact_path" | awk '{print $1}')"
8787
echo "${hash} ${{ matrix.asset_name }}" > "$checksum_path"
8888
89+
- name: Generate checksum (macOS)
90+
if: matrix.os == 'macos-latest'
91+
run: |
92+
artifact_path="target/${{ matrix.target }}/release/${{ matrix.artifact_name }}"
93+
checksum_path="target/${{ matrix.target }}/release/${{ matrix.asset_name }}.sha256"
94+
hash="$(shasum -a 256 "$artifact_path" | awk '{print $1}')"
95+
echo "${hash} ${{ matrix.asset_name }}" > "$checksum_path"
96+
8997
- name: Generate checksum (Windows)
9098
if: matrix.os == 'windows-latest'
9199
shell: pwsh

0 commit comments

Comments
 (0)