cfg/bin/update-gotools

51 lines
1.1 KiB
Text
Raw Normal View History

#!/bin/bash
set -eux
set -o pipefail
2016-07-21 13:48:49 +00:00
export GOPATH="${HOME}/gocode"
INSTALLS=(
# Go-dev related tools
'github.com/alecthomas/gometalinter'
'github.com/golang/dep/cmd/dep'
'github.com/mailgun/godebug'
'github.com/nsf/gocode'
'github.com/shuLhan/go-bindata/...'
'github.com/tools/godep'
# Vault related tools
'github.com/hashicorp/vault'
'github.com/Luzifer/vault2env'
'github.com/Luzifer/vault-patch'
# Other tools
'github.com/fatih/hclfmt'
'github.com/fiatjaf/jiq/cmd/jiq'
'github.com/hashicorp/packer'
'github.com/Luzifer/git-changerelease'
'github.com/Luzifer/password'
'github.com/Luzifer/share'
'github.com/Luzifer/short_path'
'github.com/Luzifer/slugify'
'github.com/Luzifer/str2hex'
'github.com/Luzifer/worktime'
'github.com/peco/peco/cmd/peco'
)
rm -rf ${GOPATH}
mkdir -p ${GOPATH}
2016-07-21 13:48:49 +00:00
# Create `.gopath` file for $PATH detection
touch ${GOPATH}/.gopath
for gp in ${INSTALLS[@]}; do
go get ${gp} &
done
wait
# Ensure installed tools can work
2016-07-21 13:48:49 +00:00
${GOPATH}/bin/gometalinter --install --update
vim +:GoInstallBinaries +:qall
2016-07-21 13:48:49 +00:00