Skip to content
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.notational-fzf-vim: patch plugin to fix missing runtime dependency #80657

Merged
merged 1 commit into from Feb 25, 2020

Conversation

brettlyons
Copy link
Contributor

No description provided.

@timokau
Copy link
Member

timokau commented Feb 21, 2020

Did you run some kind of formatter? There are a lot of irrelevant changes in the diff.

@brettlyons
Copy link
Contributor Author

Yeah, sorry, ran nix-fmt, reverting.

@brettlyons
Copy link
Contributor Author

So, I'm not sure if this adds rg to the path, I do know that the plugin runs execute!("rg") rather than having it coded in, so adding ripgrep to PATH made the most sense to me. Idk if buildinputs does that, or if something else is necessary?

@timokau
Copy link
Member

timokau commented Feb 21, 2020

No, buildInputs does not do that. It will only add rg to the PATH during build time, but not during runtime.

Unfortunately we don't currently have an easy way to do this at runtime. It could be done in combination with plugin management (simply adding an appropriate snippet to the generated vimrc), but we don't currently do that.

To make sure ripgrep can be found by the plugin, you will need to patch the plugin's source to contain an absolute path to ripgrep. You can do that substituteInPlace / sed / patch files. You can either directly modify the references to rg or add some code to prepend ripgrep to PATH.

@brettlyons
Copy link
Contributor Author

brettlyons commented Feb 22, 2020

python3 executable patched in too.

Copy link
Contributor

@jonringer jonringer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please clean up git history, should be a single commit

@brettlyons
Copy link
Contributor Author

brettlyons commented Feb 23, 2020

Okay, that should do it, tested and working. Thanks for patience with experimentation.

@brettlyons brettlyons changed the title Add ripgrep, fzf, fzf-vim as notational-fzf-vim dependency Fix notational-fzf-vim dependency overrides Feb 23, 2020
@brettlyons brettlyons changed the title Fix notational-fzf-vim dependency overrides vimPlugin.notational-fzf-vim: patch plugin to fix missing runtime dependency Feb 23, 2020
@brettlyons brettlyons changed the title vimPlugin.notational-fzf-vim: patch plugin to fix missing runtime dependency vimPlugins.notational-fzf-vim: patch plugin to fix missing runtime dependency Feb 23, 2020
Copy link
Member

@timokau timokau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Though keep in mind that this fix is pretty brittle, which is why appending to PATH is somewhat nicer. Still, this is a clear improvement and can be merged if @jonringer agrees.

@timokau
Copy link
Member

timokau commented Feb 25, 2020

Thanks!

@timokau timokau merged commit b8a0058 into NixOS:master Feb 25, 2020
@brettlyons brettlyons deleted the patch-1 branch February 25, 2020 00:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants