Merge pull request #838 from MunifTanjim/add_go_plugin

add go plugin
pull/840/head
Nils Winkler 2016-11-21 08:30:09 +01:00 committed by GitHub
commit 990d7f314e
1 changed files with 11 additions and 0 deletions

View File

@ -0,0 +1,11 @@
#!/usr/bin/env bash
cite about-plugin
about-plugin 'go environment variables & path configuration'
[ ! command -v go &>/dev/null ] && return
export GOROOT=${GOROOT:-$(go env | grep GOROOT | cut -d'"' -f2)}
pathmunge "${GOROOT}/bin"
export GOPATH=${GOPATH:-"$HOME/.go"}
pathmunge "${GOPATH}/bin"