Sublime Forum

An opinionated plugin for Go


Hey everyone!

I’m a long time lurker and a sublime text user, over the past few months I’ve been developing a Go plugin for sublime mostly for personal use, I’ve been using it for a few months and it now reached a point where I feel confident someone else might find it useful.

Even though there is already a plugin for Go (GoSublime), I wanted something a bit different:

  • Only depend on well known Go tools
  • Pure python
  • Async commands by default
  • Inline vet/lint/test errors
  • Zero configuration
  • Use go env(1)
  • Transparent support for go modules.
  • Ascii spinner when guru(1) takes a lot of time to find the source :frowning_face:
  • Well tested

The plugin is also very minimal, it does not contain keybindings, mouse maps and other sources, just some *.py files, it lets you choose how and when to invoke its commands.

Here’s a list of commands the plugin provides:

  • go_fmt ⋅ via goimports(1)
  • go_source ⋅ via guru(1)
  • go_lint ⋅ via golint(1)
  • go_vet ⋅ via go vet(1)
  • go_escape ⋅ via go build -gcflags=-m
  • go_test ⋅ via go test(1)
  • go_(add, clear)_tags ⋅ via gomodifytags(1)

For now, the plugin is only tested on OSX sublime>=3207, I haven’t had time to test it on other platforms or sublime versions.

I hope that some of you would find it useful and maybe even improve it :slight_smile: