GitHub picture of ramblehead

Go IDE Configuration Notes

Collection Go IDE Configuration hints and resource references. These hints were tested on Ubuntu 22.04 LTS.

Install Go

Download Go language from go.dev and Unpack to corresponding stow directory /usr/local/stow/go<version>, such as: /usr/local/stow/go1.22.0.linux-amd64

Then install via stow:

# cd /usr/local/stow
# stow go<version>

Copy the following file to /etc/profile.d

# go.sh
export PATH=$PATH:/usr/local/go/bin

Add the following line to ~/etc/profile.d:

export PATH=$PATH:$HOME/go/bin

Restart.

References

Install gopls – the Go language server

Install gopls:

go install golang.org/x/tools/gopls@latest

References

Install golangci-lint-langserver

Install golangci-lint:

$ curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.56.1

Install golangci-lint-langserver:

go install github.com/nametake/golangci-lint-langserver@latest

References

gomacro - Go REPL

Install gomacro:

go install github.com/cosmos72/gomacro@latest

References