From 814a88a69bae783ed825b227e366947c45b8b2b3 Mon Sep 17 00:00:00 2001 From: zramsay Date: Wed, 14 Nov 2018 15:41:14 -0500 Subject: [PATCH] more maintainable/useful install scripts --- scripts/install/install_tendermint_arm.sh | 12 +++++++----- scripts/install/install_tendermint_bsd.sh | 8 +++++--- scripts/install/install_tendermint_ubuntu.sh | 12 +++++++----- 3 files changed, 19 insertions(+), 13 deletions(-) diff --git a/scripts/install/install_tendermint_arm.sh b/scripts/install/install_tendermint_arm.sh index df27fbfc3..2e8d50aef 100644 --- a/scripts/install/install_tendermint_arm.sh +++ b/scripts/install/install_tendermint_arm.sh @@ -13,19 +13,21 @@ REPO=github.com/tendermint/tendermint # change this to a specific release or branch BRANCH=master +GO_VERSION=1.11.2 + sudo apt-get update -y # get and unpack golang -curl -O https://storage.googleapis.com/golang/go1.11.2.linux-armv6l.tar.gz -tar -xvf go1.11.2.linux-armv6l.tar.gz +curl -O https://storage.googleapis.com/golang/go$GO_VERSION.linux-armv6l.tar.gz +tar -xvf go$GO_VERSION.linux-armv6l.tar.gz # move go folder and add go binary to path sudo mv go /usr/local echo "export PATH=\$PATH:/usr/local/go/bin" >> ~/.profile -# create the goApps directory, set GOPATH, and put it on PATH -mkdir goApps -echo "export GOPATH=$HOME/goApps" >> ~/.profile +# create the go directory, set GOPATH, and put it on PATH +mkdir go +echo "export GOPATH=$HOME/go" >> ~/.profile echo "export PATH=\$PATH:\$GOPATH/bin" >> ~/.profile source ~/.profile diff --git a/scripts/install/install_tendermint_bsd.sh b/scripts/install/install_tendermint_bsd.sh index 5b30eab31..0f7ef9b5e 100644 --- a/scripts/install/install_tendermint_bsd.sh +++ b/scripts/install/install_tendermint_bsd.sh @@ -14,6 +14,9 @@ # change this to a specific release or branch set BRANCH=master +set REPO=github.com/tendermint/tendermint + +set GO_VERSION=1.11.2 sudo pkg update @@ -21,8 +24,8 @@ sudo pkg install -y gmake sudo pkg install -y git # get and unpack golang -curl -O https://storage.googleapis.com/golang/go1.11.freebsd-amd64.tar.gz -tar -xvf go1.11.freebsd-amd64.tar.gz +curl -O https://storage.googleapis.com/golang/go$GO_VERSION.freebsd-amd64.tar.gz +tar -xvf go$GO_VERSION.freebsd-amd64.tar.gz # move go folder and add go binary to path sudo mv go /usr/local @@ -38,7 +41,6 @@ echo "set path=($path $GOPATH/bin)" >> ~/.tcshrc source ~/.tcshrc # get the code and move into repo -set REPO=github.com/tendermint/tendermint go get $REPO cd "$GOPATH/src/$REPO" diff --git a/scripts/install/install_tendermint_ubuntu.sh b/scripts/install/install_tendermint_ubuntu.sh index 29e975088..91ca1598d 100644 --- a/scripts/install/install_tendermint_ubuntu.sh +++ b/scripts/install/install_tendermint_ubuntu.sh @@ -13,20 +13,22 @@ REPO=github.com/tendermint/tendermint # change this to a specific release or branch BRANCH=master +GO_VERSION=1.11.2 + sudo apt-get update -y sudo apt-get install -y make # get and unpack golang -curl -O https://storage.googleapis.com/golang/go1.11.linux-amd64.tar.gz -tar -xvf go1.11.linux-amd64.tar.gz +curl -O https://storage.googleapis.com/golang/go$GO_VERSION.linux-amd64.tar.gz +tar -xvf go$GO_VERSION.linux-amd64.tar.gz # move go folder and add go binary to path sudo mv go /usr/local echo "export PATH=\$PATH:/usr/local/go/bin" >> ~/.profile -# create the goApps directory, set GOPATH, and put it on PATH -mkdir goApps -echo "export GOPATH=$HOME/goApps" >> ~/.profile +# create the go directory, set GOPATH, and put it on PATH +mkdir go +echo "export GOPATH=$HOME/go" >> ~/.profile echo "export PATH=\$PATH:\$GOPATH/bin" >> ~/.profile source ~/.profile