fbt: added support for FBT_NO_SYNC environment variable to skip submodule update at start (#1363)

This commit is contained in:
hedger
2022-07-04 20:38:18 +03:00
committed by GitHub
parent 6b6ea44802
commit 43fd2e4433
5 changed files with 18 additions and 225 deletions

13
fbt
View File

@@ -5,12 +5,13 @@ set -e
SCRIPTDIR="$( dirname -- "$0"; )";
SCONS_EP=${SCRIPTDIR}/lib/scons/scripts/scons.py
if [[ -d .git ]]; then
git submodule update --init
else # Not in a git repo
echo Not in a git repo, please clone with git clone --recursive
# Return error code 1 to indicate failure
exit 1
if [[ -z "${FBT_NO_SYNC:-}" ]] ; then
if [[ -d .git ]]; then
git submodule update --init
else
echo Not in a git repo, please clone with git clone --recursive
exit 1
fi
fi
SCONS_DEFAULT_FLAGS="-Q --warn=target-not-built"