标签 环境配置 下的文章

Go语言环境配置

0x01 brew大法好

Brew大法好,用过都说好,它好我也好。

安装brew

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
//安装成功后更新
brew update

安装Go

brew install go
==> Downloading https://homebrew.bintray.com/bottles/go-1.5.1.yosemite.bottle.ta
######################################################################## 100.0%
==> Pouring go-1.5.1.yosemite.bottle.tar.gz
==> Caveats
As of go 1.2, a valid GOPATH is required to use the `go get` command:
  https://golang.org/doc/code.html#GOPATH

You may wish to add the GOROOT-based install location to your PATH:
  export PATH=$PATH:/usr/local/opt/go/libexec/bin
...

阅读全文 >>