neovimUtils.makeNeovimConfig: add pathDependencies#208029
neovimUtils.makeNeovimConfig: add pathDependencies#208029figsoda wants to merge 5 commits intoNixOS:masterfrom
Conversation
|
I dont see the point of the MR (which could have used a better description). What problem does it solve ? introducing a pathDependencies seems redundant with what we have already aka |
|
this adds things to this is more similar to |
|
this could become confusing very fast, better not rely on PATH too much. Furthermore the nvim-teal-maker seems to work here so why is the change needed ? |
could you elaborate?
This change is not needed, but I do think it is nice to not have to patch things as it is hard to maintain, and generated packages like vim plugins are usually not given the most thorough reviews and tests
I do like the idea of #172538, but I don't think it solves the exact problem this one solves. not all plugins provide options that allow you to specify path to binaries with configuration, and nvim-teal-maker is an example of that |
|
Are there any updates to this PR, it would be an extremely useful addition! |
|
+1 to this PR, having a wrapper-esque PATH extension with derivations is very useful for neovim, particularly for consolidating dependencies inside the derivation and not requiring them more globally. I think a great accompanying PR (not necessarily by author of this PR) to declutter and clarify |
| substituteInPlace lua/tealmaker/init.lua \ | ||
| --replace cyan ${luaPackages.cyan}/bin/cyan | ||
| ''; | ||
| passthru.pathDependencies = [ luaPackages.cyan ]; |
There was a problem hiding this comment.
Can you elaborate on this change. How does it replicate the substituteInPlace from the previous diff?
Ah I see, this passes the derivation directly into makeWrapper, very cool, but a little bit indirect. I think some form of propagated deps may be better here.
|
this was made achievable via plugins @Frontear wrapNeovimUnstable is now documented at https://nixos.org/manual/nixpkgs/unstable/#neovim-custom-configuration . There are still a few problems to solve such as lua transitive dependencies (soon), how to expose lua config. There are many usecases (wrapped vs unwrapped in home-manager) and lack of typing in nix makes exposing/evoling the API hard. We try to maintain backwards compatibility as well since neovim is crucial to many people. We are getting there though.
What do you have in mind ? |
Description of changes
I couldn't figure how to do this for vim, so we can only adopt this for neovim plugins for now
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)nixos/doc/manual/md-to-db.shto update generated release notes