Skip to content

Commit

Permalink
fix: add a BUILD tag if it's not a PR merge (#256)
Browse files Browse the repository at this point in the history
* fix: add KERAMIK_NETWORK_NAME to github env

* fix: use sha if not PR
  • Loading branch information
3benbox authored Feb 1, 2024
1 parent 34289ae commit 25e70b3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/rust-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,11 @@ jobs:
name: Build and Publish Docker Image
id: build
run: |
BUILD_TAG=$(echo ${{ github.event.pull_request.head.sha }} | head -c 12)
if [ "${{ github.event_name }}" == "pull_request" ]; then
BUILD_TAG=$(echo ${{ github.event.pull_request.head.sha }} | head -c 12)
else
BUILD_TAG=$(echo ${{ github.sha }} | head -c 12)
fi
make SHA_TAG="$BUILD_TAG" publish-docker
echo "Build tag:"
echo ${BUILD_TAG}
Expand Down

0 comments on commit 25e70b3

Please sign in to comment.