Merge pull request 'Fix build script' (#240) from feat/ci into master
Reviewed-on: #240
This commit is contained in:
commit
f5940f995e
1 changed files with 4 additions and 3 deletions
|
@ -20,14 +20,15 @@ install_artifact() {
|
|||
cd "repo"
|
||||
|
||||
PR=${PR:-}
|
||||
ref=$(cat .git/ref || echo "HEAD")
|
||||
|
||||
if [ -n "$PR" ]; then
|
||||
title "PR: $(echo "$PR" | jq '.number') - $(echo "$PR" | jq '.title')"
|
||||
ref="pr-$(echo "$PR" | jq '.number')-$(git rev-parse --short "$(cat .git/ref || echo "HEAD")" 2>/dev/null || echo 'manual')"
|
||||
ref="pr-$(echo "$PR" | jq '.number')-$(git rev-parse --short "$ref" 2>/dev/null || echo 'manual')"
|
||||
elif [ -f ".git/branch" ]; then
|
||||
ref=$(cat .git/branch)-$(git rev-parse --short $ref)
|
||||
ref=$(cat .git/branch)-$(git rev-parse --short "$ref")
|
||||
else
|
||||
ref=$(git rev-parse --short "$(cat .git/ref || echo "HEAD")")
|
||||
ref=$(git rev-parse --short "$ref")
|
||||
fi
|
||||
|
||||
title "Version: '$ref'"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue