hhstore / blog

My Tech Blog: about Mojo / Rust / Golang / Python / Kotlin / Flutter / VueJS / Blockchain etc.
https://github.com/hhstore/blog/issues
284 stars 23 forks source link

Golang: Setup Golang Development environment #89

Open hhstore opened 5 years ago

hhstore commented 5 years ago

ref:

hhstore commented 5 years ago

For Mac OSX:

install go:

# 更新源:
brew update

# 初次安装:
brew install go

# 版本更新:
brew upgrade go

# 清理已安装的旧版本:
 brew cleanup
You may wish to add the GOROOT-based install location to your PATH:
  export PATH=$PATH:/usr/local/opt/go/libexec/bin
==> Summary
🍺  /usr/local/Cellar/go/1.11: 9,273 files, 403.9MB
#
go version

#
go env

zsh Settings:

#-------------------------------
# set GOPATH:
#-------------------------------

# go:
export PATH=$PATH:/usr/local/opt/go/libexec/bin

IDE: Goland Settings:

hhstore commented 5 years ago

Requirement:

pb:

brew install protobuf

consul


docker pull consul

# run: