about summary refs log tree commit diff
path: root/pkgs/applications/editors/vim/plugins/build-vim-plugin.nix
AgeCommit message (Collapse)AuthorFilesLines
2024-04-20toVimPlugin: prepends 'vimPlugin' to the nameMatthieu Coudron1-2/+1
Neovim plugins built with buildNeovimPlugin are based on derivations from the lua package set, ie., they are a flat-install (no share/lua/5.1 nesting) with some post-processing. While debugging, I noticed their name lacked the vimplugin prefix, making them a bit harder to diagnose if the derivation was the vimplugin or not. So I hardcoded 'namePrefix' (why let the user change that ?) and moved it to toVimPlugin so it applies to lua-based plugins as well. Before this PR: ➜ nix-build -A vimPlugins.plenary-nvim /nix/store/zyvdf7c1k4q2ykg6jydpf5c31g9j921s-lua5.1-plenary.nvim-scm-1-unstable-2024-03-25 After this PR ➜ nix-build -A vimPlugins.plenary-nvim /nix/store/dy4rjzjbhshi109i6969f39vd9xbjgs1-vimplugin-lua5.1-plenary.nvim-scm-1-unstable-2024-03-25
2023-09-27vimUtils: buildVimPluginFrom2Nix renamed to buildVimPluginMatthieu Coudron1-7/+2
the `from2Nix` suffix is a legacy from vim2nix but we dont use that anymore. It makes the name of the function unusual and long.
2022-12-23vimUtils.buildVimPlugin: formatfigsoda1-40/+39
2022-12-23vimUtils.buildVimPlugin: set meta.platformsfigsoda1-0/+5
2022-10-09buildVimPlugin: deprecate `rtp` attributeilkecan1-2/+2
2022-10-09vimUtils.buildVimPlugin: prevent building twiceilkecan1-3/+7
Don't set the `rtp` attribute using `overrideAttrs`. `overrideAttrs` passes the attribute to the builder hence creates a different derivation. This made vim plugins being built twice.
2022-06-19vimPlugins: use lua derivation if it exists (#178180)Matthieu Coudron1-7/+3
Neovim plugins are now more often than not written in lua. One advantage of the lua ecosystem over vim's is the existence of luarocks and the rockspec format, which allows to specify a package dependencies formally. I would like more neovim plugins to have a formal description, "rockspec" being the current candidate. This MR allows to use nix lua packages as neovim plugins, so as to enjoy every benefit that rockspecs bring: - dependdency discovery - ability to run test suite - luarocks versioning - rockspec metadata the vim update.py script will check if an attribute with the vim plugin pname exists in lua51Packages. If it does, it uses buildNeovimPluginFrom2Nix on it, which modifies the luarocks config to do an almost flat install (luarocks will install the package in the lua folder instead of share/5.1/lua etc). It also calls toVimPlugin on it to get all the vim plugin niceties. The list of packages that could benefit from this is available at https://luarocks.org/labels/neovim but I hope it grows.
2022-05-29vimUtils.buildVimPlugin: only add vimCommandCheckHook toNick Cao1-2/+1
nativeBuildInputs when native compiling
2022-05-11buildLuaPlugin: convert the addRtp callMatthieu Coudron1-2/+5
since it was breaking overrideAttrs.
2022-05-11buildNeovimPluginFrom2Nix: use neovimRequireCheckHookMatthieu Coudron1-7/+2
and removed the addRtp call that was breaking overrideAttrs
2022-05-11buildVimPlugin: check that neovim can require the module.Matthieu Coudron1-1/+2
Add: ``` doInstallCheck = true; nvimRequireCheck = "toto"; ``` to your vimPluginCall.
2022-04-30buildVimPlugin: add vimCommandCheckHookMatthieu Coudron1-0/+2
Modeled after pythonImportCheckHook, this checks a command can be run once the plugin is installed
2022-02-24Move misc/vim-plugins to applications/editors/vim/pluginsAndersonTorres1-0/+52