aboutsummaryrefslogtreecommitdiffstats
path: root/install.sh
diff options
context:
space:
mode:
authorEric Robitaille <eric@vianet.ca>2014-11-21 04:02:24 +0800
committerEric Robitaille <eric@vianet.ca>2014-11-21 04:02:24 +0800
commitc0bbb7e69a0f34020f211061aaa842f1bbedb507 (patch)
tree064206da31ebdc5904b53108e7c4eb728280c29e /install.sh
parentd5ac24907e0e98329d2db0d982c035f9d2635c6d (diff)
downloaddexon-c0bbb7e69a0f34020f211061aaa842f1bbedb507.tar.gz
dexon-c0bbb7e69a0f34020f211061aaa842f1bbedb507.tar.zst
dexon-c0bbb7e69a0f34020f211061aaa842f1bbedb507.zip
fix for install script devel
Diffstat (limited to 'install.sh')
-rwxr-xr-xinstall.sh18
1 files changed, 12 insertions, 6 deletions
diff --git a/install.sh b/install.sh
index 1f03f3f99..39212c3ed 100755
--- a/install.sh
+++ b/install.sh
@@ -1,14 +1,20 @@
#!/bin/sh
if [ "$1" == "" ]; then
- echo "Usage $0 executable ethereum branch develop"
- echo "executable ethereum or mist"
- echo "branch develop or master"
+ echo "Usage $0 executable branch"
+ echo "executable ethereum | mist"
+ echo "branch develop | master"
exit
fi
exe=$1
branch=$2
+branchPath=""
+
+# Set branchPath for develop as executables have moved
+if [ "$branch" == "develop" ]; then
+ branchPath="cmd/"
+fi
# Test if go is installed
command -v go >/dev/null 2>&1 || { echo >&2 "Unable to find 'go'. This script requires go."; exit 1; }
@@ -19,8 +25,8 @@ if [ "$GOPATH" == "" ]; then
exit
fi
-echo "go get -u -d github.com/ethereum/go-ethereum/cmd/$exe"
-go get -v -u -d github.com/ethereum/go-ethereum/cmd/$exe
+echo "go get -u -d github.com/ethereum/go-ethereum/$branchPath$exe"
+go get -v -u -d github.com/ethereum/go-ethereum/$branchPath$exe
if [ $? != 0 ]; then
echo "go get failed"
exit
@@ -31,7 +37,7 @@ cd $GOPATH/src/github.com/ethereum/go-ethereum
git checkout $branch
echo "go-ethereum"
-cd $GOPATH/src/github.com/ethereum/go-ethereum/cmd/$exe
+cd $GOPATH/src/github.com/ethereum/go-ethereum/$branchPath$exe
git checkout $branch
if [ "$exe" == "mist" ]; then