From 10ebaecadbf81d7995b5b21179c42db92a2a52f7 Mon Sep 17 00:00:00 2001 From: Tom Most Date: Tue, 27 Aug 2024 17:32:20 -0700 Subject: [PATCH] Generate `.sha256sum` files for release artifacts (#2323) --- .github/workflows/release.yaml | 4 +++- bin/package | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 845046afbc..8f987c01c0 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -99,7 +99,9 @@ jobs: if: ${{ startsWith(github.ref, 'refs/tags/') }} with: draft: false - files: ${{ steps.package.outputs.archive }} + files: | + ${{ steps.package.outputs.archive }} + ${{ steps.package.outputs.archive }}.sha256sum prerelease: ${{ steps.ref-type.outputs.value != 'release' }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/bin/package b/bin/package index d7949224b6..32ea2a8b3f 100755 --- a/bin/package +++ b/bin/package @@ -45,10 +45,12 @@ case $OS in ARCHIVE=$DIST/just-$VERSION-$TARGET.tar.gz tar czf $ARCHIVE * echo "archive=$ARCHIVE" >> $GITHUB_OUTPUT + shasum -a 256 $ARCHIVE > $ARCHIVE.sha256sum ;; windows-latest) ARCHIVE=$DIST/just-$VERSION-$TARGET.zip 7z a $ARCHIVE * echo "archive=`pwd -W`/just-$VERSION-$TARGET.zip" >> $GITHUB_OUTPUT + sha256sum $ARCHIVE > $ARCHIVE.sha256sum ;; esac