[build.sh] Version definition will now be groked from VERSION file if not in git repository
This commit is contained in:
parent
75a98d636e
commit
53ab36c76d
1 changed files with 2 additions and 1 deletions
3
build.sh
3
build.sh
|
@ -29,7 +29,8 @@ gen_help() {
|
|||
|
||||
gen_env() {
|
||||
echo -e "#!/bin/bash\n"
|
||||
echo "VERSION=$(git describe --tags)"
|
||||
[[ $(git describe --tags) ]] && VERSION=$(git describe --tags) || VERSION=$(cat VERSION)
|
||||
echo "VERSION=${VERSION}"
|
||||
awk '!/^ *#/ && NF' src/env
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue