mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2025-04-28 14:15:06 +03:00
Fix semver when git history is not present
This commit is contained in:
parent
4532d0e0c8
commit
d0c2ce90bb
2 changed files with 7 additions and 2 deletions
|
@ -16,6 +16,11 @@ PATCH=$(git rev-list $TAG..master --count --merges --grep="from $DEVELOPBRANCH"
|
|||
if [ $? != 0 ]; then
|
||||
PATCH=$(git rev-list HEAD --count 2>/dev/null)
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
printf 'unknown'
|
||||
exit -1
|
||||
fi
|
||||
|
||||
printf 'v0.0.%d' "$PATCH"
|
||||
exit -1
|
||||
fi
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue