From cd7582b5533ce19a5f30d968e9669d50a1d2bae2 Mon Sep 17 00:00:00 2001 From: intl-man Date: Sun, 14 Nov 2021 23:12:13 +0800 Subject: [PATCH] Fix for setting the commit sha. --- .github/workflows/release.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 94f28f36dc..a4dee3ea30 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -35,6 +35,11 @@ jobs: docker push sifchain/sifnoded:${{ steps.version.outputs.version }} docker push sifchain/ebrelayer:${{ steps.version.outputs.version }} + - name: Get commit hash + id: hash + run: | + echo "::set-output name=sha_short::$(git rev-parse --short HEAD)" + - name: Release a new sifnoded binary uses: ./sifchain-devops/release with: @@ -44,5 +49,5 @@ jobs: goversion: "1.16" project_path: "./cmd/sifnoded" binary_name: "sifnoded" - ldflags: "-X github.com/cosmos/cosmos-sdk/version.Name=sifchain -X github.com/cosmos/cosmos-sdk/version.ServerName=sifnoded -X github.com/cosmos/cosmos-sdk/version.ClientName=sifnoded -X github.com/cosmos/cosmos-sdk/version.Version=${{ steps.version.outputs.version }} -X github.com/cosmos/cosmos-sdk/version.Commit=${{ env.GITHUB_SHA }}" + ldflags: "-X github.com/cosmos/cosmos-sdk/version.Name=sifchain -X github.com/cosmos/cosmos-sdk/version.ServerName=sifnoded -X github.com/cosmos/cosmos-sdk/version.ClientName=sifnoded -X github.com/cosmos/cosmos-sdk/version.Version=${{ steps.version.outputs.version }} -X github.com/cosmos/cosmos-sdk/version.Commit=${{ steps.hash.outputs.sha_short }}" sha256sum: true