Hi! I made some Go customizations for atom, and there were a few things that I thought worked pretty well, maybe consider adding them to this project:
1) Auto GOPATH detection: since all code is located underneath a canonical GOPATH, if the GOPATH is not set, traverse upward a few directories until you find one with a "src" folder in it. This means that I don't have to launch it from a terminal and deal with environment variables. Also, I use a GOPATH per project, so as long as each window auto-detects its own GOPATH, that works great.
2) Cross-compile all the tools (gocode, etc) for the most common platforms, presumably windows and mac, and include them in the extension so that it doesn't rely on auto-install or whatever and just works out of the box.
Hi! My Go project directory has ~2 million data files under a directory called test. When I open the project directory, VS Code starts going through all of them, consuming a lot of memory and IO bandwidth. Is there a way to make it ignore that directory?
I tried "files.exclude" which hides it from the sidebar, but VS Code still tries to walk the entire directory tree.
One of my required features is seeing the method signature when my cursor is on the method name; I don't want to have to enter a command to see the signature. In sublime, the bottom bar will passively show me `func Unmarshal(data []byte, v interface{}) error` when I cursor over json.Unmarshal. I'd really like it if it also showed me the type of the variable I was cursored over, but I digress. Is this possible in your extension?
Thanks for this extension, but I struggle with setting it up. How would one build a Go program from inside the IDE? My go program is git controlled, but the IDE does not seem to notice it.
Can jump to definition jump to a definition in an open file instead of opening a duplicate file? Is this handled within the extension or vscode itself?
Thanks for the hard work btw, vscode+go has made my team much more productive.
Go to Definition will navigate to the definition in an existing open document or open the document if needed. This works across packages in your GOPATH, and also for core Go APIs in GOROOT.
This is all handled in VS Code itself through it's (relatively high-level) extension API[0].
I don't think it does. I'm trying to find flags or anything to make it know what gb is. In the gopath, things just work. In a gb project it just says "no buildable files" because it doesn't know to do `gb build`. Tried some other projects like atocker but then they don't seem to play nice with docker-machine.