1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-12-22 01:57:12 -05:00

minor: ignore error on mkdir in install.sh

This commit is contained in:
adoot 2015-12-25 02:11:13 +00:00
parent 20b64ecdfe
commit 3bbb1c6a93

View File

@ -9,23 +9,15 @@ if [ "$ARCH" == "i686" ] || [ "$ARCH" == "i386" ]; then
GO_CUR=${GO_X86}
fi
function git_not_installed {
git --version 2>&1 >/dev/null
GIT_IS_AVAILABLE=$?
return $GIT_IS_AVAILABLE
}
if [ git_not_installed ]; then
apt-get install git -y
fi
which git > /dev/null || apt-get install git -y
if [ -z "$GOPATH" ]; then
curl -o go_latest.tar.gz ${GO_CUR}
tar -C /usr/local -xzf go_latest.tar.gz
rm go_latest.tar.gz
export PATH=$PATH:/usr/local/go/bin
mkdir /v2ray
mkdir /v2ray &> /dev/null
export GOPATH=/v2ray
fi