The file https://github.com/NixOS/nixpkgs/blob/master/pkgs/misc/vim-plugins/vim-plugin-names lists all supported vim plugins. It's not always straightforward to match the plugin name from that list with the string I have to add to programs.vim.plugins.
vim-sensible, I can add "sensible" or "vim-sensible" to the list.fzf, there seems no correct string. None of "junegunn/fzf.vim", "junegunn/fzf", "fzf.vim" or "fzf" work. I always get error: attribute ... missing.You can see all names in generated.nix, for fzf it's fzf-vim.
The . seems to be replaced with a -.
https://github.com/NixOS/nixpkgs/blob/master/pkgs/misc/vim-plugins/generated.nix#L531
So it seems like a documentation problem. If someone can explain what the algorithm is (I stared at the code and don't understand it) I'd update the manpage.
I guess you could check the output of
$ nix-env -f '<nixpkgs>' -qaP -A vimPlugins --description
vimPlugins.pluginnames2nix vim-plugin-names-to-nix
vimPlugins.a-vim vimplugin-a-vim-2010-11-06
vimPlugins.ack-vim vimplugin-ack-vim-2018-02-28
vimPlugins.acp vimplugin-acp-2013-02-05
vimPlugins.agda-vim vimplugin-agda-vim-2017-11-21
…
@turion the algorithm (for the name) is here.
https://github.com/NixOS/nixpkgs/blob/master/pkgs/misc/vim-plugins/update.py#L101
Created PR that improves documentation using command suggested by @rycee. Thank you for rising the issue and I hope the PR solves it @turion.
@uvNikita, that's a good idea!
Awesome!
Most helpful comment
I guess you could check the output of