I’ve recently switched to Atom from Sublime Text for web development. The transition was relatively painless since many of the keyboard shortcuts and capabilities are the same in. I really enjoy usig Atom and want to have that same experience with programming in Go. This documents my Go setup in Atom.
Install and Configuration Steps
Install go-plus
Set the go-plus
GOPATH
settingIdeally the Atom application process should have
GOPATH
in itsENV
and you shouldn’t have to set this.Install atom build
Set build
Panel Visibility
setting toKeep Visible
Add
.atom-build.json
to root of your project directory
{
"cmd": "$GOROOT/bin/go run {FILE_ACTIVE}",
"shell": true,
"env": {
"GOROOT": "/usr/local/go",
"GOPATH": "/Users/pfeilbr/go"
}
}
Keyboard Shortcuts
cmd-alt-b
- run current filecmd-alt-g
- goto definitionctrl-space
- code completion
Twitter • Reddit