From 3bbb1c6a938c6da1dd04883f5cff412154d32cb3 Mon Sep 17 00:00:00 2001 From: adoot Date: Fri, 25 Dec 2015 02:11:13 +0000 Subject: [PATCH] minor: ignore error on mkdir in install.sh --- release/install.sh | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/release/install.sh b/release/install.sh index 4280a9307..1972c3139 100755 --- a/release/install.sh +++ b/release/install.sh @@ -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