summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorruki <[email protected]>2019-06-27 23:58:09 +0800
committerruki <[email protected]>2019-06-27 17:48:54 +0800
commit10f5a0cf4441565b66d9fe2682ee78fbaab73fa9 (patch)
treeb7b19f2971d7228fd7119b4dcf52d83ba5d78266 /scripts
parent8361524676812b48cb373b3e8e4212acd54c24dd (diff)
improve get.sh
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/get.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/get.sh b/scripts/get.sh
index 9b06b49b6..ed8db71be 100755
--- a/scripts/get.sh
+++ b/scripts/get.sh
@@ -111,7 +111,9 @@ then
git clone --depth=1 -b "$branch" "https://github.com/$mirror/xmake.git" --recursive $projectdir || my_exit "$(echo -e 'Clone Fail\nCheck your network or branch name')"
fi
else
- git submodule update --init --recursive
+ if [ -d '.git' ]; then
+ git submodule update --init --recursive
+ fi
projectdir=`pwd`
fi
if [ 'x__install_only__' != "x$2" ]