-
-
Notifications
You must be signed in to change notification settings - Fork 14.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vimPlugins: vim-go: make gocode, gocode-mod and keyify available to it #49815
Conversation
@GrahamcOfBorg build gocode gocode-gomod vimPlugins.vim-go |
Success on x86_64-linux (full log) Attempted: gocode, gocode-gomod Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: gocode, gocode-gomod Partial log (click to expand)
|
@@ -261,6 +261,9 @@ with generated; | |||
asmfmt | |||
delve | |||
errcheck | |||
go-tools | |||
gocode | |||
gocode-gomod |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does gocode-gomode? It looks a bit like gocode.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was taken by this as well. gocode-gomod is a fork of gocode with support for Go modules. Unfortunately, neither project can replace the other!
See gocode README https://github.com/mdempsky/gocode#githubcommdempskygocode
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is vim-go smart enough to switch between the too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Success on x86_64-linux (full log) Attempted: gocode, gocode-gomod, vimPlugins.vim-go Partial log (click to expand)
|
Success on aarch64-linux (full log) Attempted: gocode, gocode-gomod The following builds were skipped because they don't evaluate on aarch64-linux: vimPlugins.vim-go Partial log (click to expand)
|
Motivation for this change
This is a continuation of #49669, it seems that I have missed the gocode-gomod binary and I forgot to add gocode and go-tools to the vim-go path.
With regards to the
sed
change, initially, I patched go#path#CheckBinPath() which is called anytime a binary is called. However, there's also this call left unpached that can cause confusion if the user runs:GoInstallBinaries
as it won't see the nix-store paths. In this PR, I decided to patch go#config#BinPath() which is called by any call out to a binary. As an added bonus, this patch patches the default go_bin_path, so a user can simplylet g:go_bin_path="..."
from the vimrc to override it.Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)cc @Mic92