build.sh: fix handling git safe protection
This commit is contained in:
parent
44bd9a6446
commit
3a443e1fa5
1 changed files with 6 additions and 0 deletions
6
build.sh
6
build.sh
|
@ -9,6 +9,12 @@ cd $( dirname $0 )
|
|||
echo "Clean previous build..."
|
||||
rm -fr dist deb_dist
|
||||
|
||||
if [ -n "$CI" -a $UID -eq 0 ]
|
||||
then
|
||||
echo "CI environment detected, set current directory as git safe for root"
|
||||
git config --global --add safe.directory $(pwd)
|
||||
fi
|
||||
|
||||
echo "Detect version using git describe..."
|
||||
VERSION="$( git describe --tags|sed 's/^[^0-9]*//' )"
|
||||
|
||||
|
|
Loading…
Reference in a new issue