mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2025-02-24 22:58:43 +01:00
prevent double entry
This commit is contained in:
parent
7cce64eb1b
commit
40f8d114a5
1 changed files with 7 additions and 5 deletions
|
@ -48,11 +48,13 @@ if [ ${goInstalled} -eq 0 ];then
|
||||||
export PATH=$PATH:$GOROOT/bin
|
export PATH=$PATH:$GOROOT/bin
|
||||||
export GOPATH=/usr/local/gocode
|
export GOPATH=/usr/local/gocode
|
||||||
export PATH=$PATH:$GOPATH/bin
|
export PATH=$PATH:$GOPATH/bin
|
||||||
sudo bash -c "echo 'GOROOT=/usr/local/go' >> /etc/profile"
|
if [ $(cat /etc/profile | grep -c "GOROOT=") -eq 0 ]; then
|
||||||
sudo bash -c "echo 'PATH=\$PATH:\$GOROOT/bin/' >> /etc/profile"
|
sudo bash -c "echo 'GOROOT=/usr/local/go' >> /etc/profile"
|
||||||
sudo bash -c "echo 'GOPATH=/usr/local/gocode' >> /etc/profile"
|
sudo bash -c "echo 'PATH=\$PATH:\$GOROOT/bin/' >> /etc/profile"
|
||||||
sudo bash -c "echo 'PATH=\$PATH:\$GOPATH/bin/' >> /etc/profile"
|
sudo bash -c "echo 'GOPATH=/usr/local/gocode' >> /etc/profile"
|
||||||
|
sudo bash -c "echo 'PATH=\$PATH:\$GOPATH/bin/' >> /etc/profile"
|
||||||
|
fi
|
||||||
|
|
||||||
# set GOPATH https://github.com/golang/go/wiki/SettingGOPATH
|
# set GOPATH https://github.com/golang/go/wiki/SettingGOPATH
|
||||||
go env -w GOPATH=/usr/local/gocode
|
go env -w GOPATH=/usr/local/gocode
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue