feat(golang): use goenv to install and manage Go versions

This commit is contained in:
2020-09-27 18:33:31 +01:00
parent 85b13ba7e7
commit be4c3e1599
2 changed files with 35 additions and 4 deletions

8
zshenv
View File

@@ -137,10 +137,6 @@ path_append "/opt/flutter/bin/cache/dart-sdk/bin"
# Use gnu-getop if available
path_prepend "/usr/local/opt/gnu-getopt/bin"
# Go (golang) environment setup
export GOPATH="$HOME/.go"
path_prepend "$GOPATH/bin"
# Homebrew setup
export HOMEBREW_NO_ANALYTICS=1
@@ -153,6 +149,10 @@ path_prepend "/opt/emacs/bin"
# Use custom tmux install if available
path_prepend "/opt/tmux/bin"
# Go setup for golang (./zsh/golang.zsh)
path_prepend "$HOME/.goenv/shims"
export GOENV_GOPATH_PREFIX="$HOME/.goenv/go"
# Ruby setup for rbenv (./zsh/ruby.zsh)
path_prepend "$HOME/.rbenv/shims"
path_prepend "$HOME/.rbenv/bin"