This section outlines how to install tools that would aid you in developing rai
.
RAI is developed using golang which needs to be installed for code to be compiled from source. You can install Golang either through Go Version Manager(recommended) or from the instructions on the golang site. We recommend the Go Version Manager.
The following are instruction on how to install Go 1.11 through Go version manager. Go version 1.11+ is required to compile RAI.
Download the GVM using
bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer)
Add the following line to your .bashrc
(or .zshrc
if using zsh) to set up the GVM environment.
This is sometimes done for you by default.
[[ -s "$HOME/.gvm/scripts/gvm" ]] && source "$HOME/.gvm/scripts/gvm"
You can then install the Go 1.11 binary and set it as the default
gvm install go1.11 -B
gvm use go1.11 --default
gvm
will setup both your $GOPATH
and $GOROOT
and you can validate that the installation completed by invoking
$ go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/abduld/.gvm/pkgsets/go1.11/global"
GORACE=""
GOROOT="/home/abduld/.gvm/gos/go1.11"
GOTOOLDIR="/home/abduld/.gvm/gos/go1.11/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build917072201=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"
PKG_CONFIG="pkg-config"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
Install Fasd
Install VimGo
Install VSCode with Golang extension.
It's ok if some of these do not install on your system
go get github.com/klauspost/asmfmt/cmd/asmfmt && go install github.com/klauspost/asmfmt/cmd/asmfmt
go get github.com/derekparker/delve/cmd/dlv && go install github.com/derekparker/delve/cmd/dlv
go get github.com/kisielk/errcheck && go install github.com/kisielk/errcheck
go get github.com/davidrjenni/reftools/cmd/fillstruct && go install github.com/davidrjenni/reftools/cmd/fillstruct
go get github.com/mdempsky/gocode && go install github.com/mdempsky/gocode
go get github.com/rogpeppe/godef && go install github.com/rogpeppe/godef
go get github.com/zmb3/gogetdoc && go install github.com/zmb3/gogetdoc
go get golang.org/x/tools/cmd/goimports && go install golang.org/x/tools/cmd/goimports
go get github.com/golang/lint/golint && go install github.com/golang/lint/golint
go get github.com/alecthomas/gometalinter && go install github.com/alecthomas/gometalinter
go get github.com/fatih/gomodifytags && go install github.com/fatih/gomodifytags
go get golang.org/x/tools/cmd/gorename && go install golang.org/x/tools/cmd/gorename
go get github.com/jstemmer/gotags && go install github.com/jstemmer/gotags
go get golang.org/x/tools/cmd/guru && go install golang.org/x/tools/cmd/guru
go get github.com/josharian/impl && go install github.com/josharian/impl
go get honnef.co/go/tools/cmd/keyify && go install honnef.co/go/tools/cmd/keyify
go get github.com/fatih/motion && go install github.com/fatih/motion
go get github.com/koron/iferr && go install github.com/koron/iferr
go get github.com/maruel/panicparse/cmd/pp && go install github.com/maruel/panicparse/cmd/pp
go get github.com/maruel/panicparse && go install github.com/maruel/panicparse
go get github.com/DATA-DOG/goup && go install github.com/DATA-DOG/goup
go get github.com/Masterminds/glide && go install github.com/Masterminds/glide
go get github.com/golang/dep && go install github.com/golang/dep
go get github.com/alecthomas/gometalinter
go install github.com/alecthomas/gometalinter
gometalinter --install
First, install the rai-srcmanager
by
go get -u -v github.com/rai-project/rai-srcmanager
Download the required public repositories by
rai-srcmanager update --public
Now all the relevant repositories should now be in $GOPATH/src/github.com/rai-project
.
- 50 Shades of Go - Traps, Gotchas, and Common Mistakes for New Golang Devs.
- A Tour of Go - Interactive tour of Go.
- Build web application with Golang - Golang ebook intro how to build a web app with golang.
- Building Go Web Applications and Microservices Using Gin - Get familiar with Gin and find out how it can help you reduce boilerplate code and build a request handling pipeline.
- Games With Go - A video series teaching programming and game development.
- Go By Example - Hands-on introduction to Go using annotated example programs.
- Go Cheat Sheet - Go's reference card.
- Go database/sql tutorial - Introduction to database/sql.
- Golangbot - Tutorials to get started with programming in Go.
- Hackr.io - Learn Go from the best online golang tutorials submitted & voted by the golang programming community.
- How to Use Godog for Behavior-driven Development in Go - Get started with Godog — a Behavior-driven development framework for building and testing Go applications.
- Learn Go with TDD - Learn Go with test-driven development.
- Working with Go - Intro to go for experienced programmers.
- Your basic Go - Huge collection of tutorials and how to's
- Awesome Go