Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: add sha256 checksums #103

Merged
merged 7 commits into from
Oct 6, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,14 +144,20 @@ jobs:
run: |
VERSION_TAG=$(jq --raw-output '.release.tag_name' "$GITHUB_EVENT_PATH")
TARGET=x86_64-pc-windows-msvc
NAME=mask-$VERSION_TAG-$TARGET
NAME=mask-$TARGET
mkdir $NAME
mv ./target/$TARGET/release/mask.exe ./$NAME/mask.exe
7z a $NAME.zip $NAME
certutil -hashfile $NAME.zip sha256 | grep -E [A-Fa-f0-9]{64} > $NAME.zip.sha256
# NOTE: cannot use the attach-release-assets action because windows doesn't support docker-based actions.
# Luckily we can just run the bash script directly.
- name: Attach the binary to the release
shell: bash
run: ./.github/actions/attach-release-assets/run.sh ./*.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Attach the binary to the release
shell: bash
run: ./.github/actions/attach-release-assets/run.sh ./*.sha256
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if it is worth to have the hassle to change the whole bash script, so I just called it twice to upload the sha checksums as well? Is that ok?