Go Lang
Git pre-commit hook
Set up
brew install go
mkdir -p ~/src/go
ln -s ~/src/go ~/go
Inside .bash_profile
[[ -d $HOME/src/go/ ]] && export GOPATH=$HOME/src/go/
Others
export GOPATH=$(go env GOPATH)
export PATH=$PATH:$(go env GOPATH)/bin
Pros
gofmt
Cons
Uses tabs for identation
Editorconfig
https://github.com/editorconfig/editorconfig-core-go/blob/master/.editorconfig
GraphQL
https://github.com/neelance/graphql-go https://github.com/graphql-go/graphql https://github.com/graphql-go/relay
length
len("/view/")
Best Practices
https://talks.golang.org/2013/bestpractices.slide#1 https://peter.bourgon.org/go-best-practices-2016/#development-environment https://medium.com/@benbjohnson/standard-package-layout-7cdbc8391fc1 https://devhints.io/go
Examples
Wiki
https://golang.org/doc/articles/wiki/ https://golang.org/doc/articles/wiki/final.go
Last updated
Was this helpful?