Closed ChrisHines closed 8 years ago
@wbond Can you comment on what would be required to add this support to the build output console?
It looks like we need to add result_file_regex
, result_line_regex
and result_base_dir
settings to the output. I need to check and make sure those will work with the output panel name we are using. We may have to use the default build system output panel to get those commands to work.
I'll work on a CL for this.
This would definitely make the package 1000 times more useful.... being able to click on the name of the file and go to a compile error is really the main reason I'd want to build inside sublime.
The only tricky part that I can think of is the case of a multi-entry $GOPATH
. In fact, I think there are several interesting use cases to consider because the Go compiler may emit path information that is relative to some portion of the GOPATH. This may not map directly to your Sublime project folder
settings:
GOPATH=/home/jason/gosrc/
but your folders
setting in your Sublime project config points to: /home/jason/gosrc/src/github.com/jbuberel/myproject
GOPATH=/usr/src/third_party/go:/home/jason/gowork
), your Sublime project config only includes only one folder, /home/jason/gowork
, and the compile error is found in a file under /usr/src/third_party/go/src
.I'm not saying the package should support all of these, but that we should be clear about which of them are supportable.
CL posted at https://go-review.googlesource.com/#/c/16153/.
@jbuberel The filename output from go
is relative to the working directory, so I was able to get the correct behavior just by setting the result_base_dir
setting to the working directory.
Just pushed v0.8.1 tag. This feature is now available. On Windows, I am able to double-click an entry in the console output, and it will take me to that file:line combination.
Works for me on linux. Nice work! This is awesome!
When the compiler produces errors in the form
file/path.go:19 undefined asdf
we should be able to select the error or navigate to prev/next build result with the Sublime build system navigation commands. This does not seem possible yet.