-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
How to install further vim plugins? #416
Comments
Sorry, I know very little about vim nowadays but on 18.09 I get $ nix-env -f '<nixpkgs>' -qaP -A vimPlugins | egrep "(pathogen|vam)"
vimPlugins.pathogen vimplugin-vim-pathogen-2018-04-05 so at least pathogen (whatever it may be 🙂) should be available. For vam I can't help, I would guess that it mainly is an issue for Nixpkgs. |
you can add the missing plugins to nixpkgs or keep installing them manually. Parts of my plugins are handled by nixpkgs (with vam I think), the other I keep updating with vim-plug. |
|
I have a custom HM module I wrote for neovim plugins — see below: Click to view: |
@akavel Thanks for sharing your solution. |
Here's a solution I found for doing this that I think is pretty useful (using neovim & vimplug, but the same concept applies to the others, I think): # programs/neovim/custom-plugins.nix
{ pkgs, ... }:
{
onedark-vim = pkgs.vimUtils.buildVimPlugin {
name = "onedark-vim";
src = pkgs.fetchFromGitHub {
owner = "joshdick";
repo = "onedark.vim";
rev = "7f36f83f13d3bdbd3dca4e3e8b2a10a5ecdca5e9";
sha256 = "0cnn3j3invasqh5sn20gf9lvcksqhracrbyr3pn3fs9shp7f1kxw";
};
};
# ...
} See this file in action here: https://github.com/rpearce/.config/blob/master/programs/neovim/custom-plugins.nix#L4-L12 Then # programs/neovim/default.nix
let
plugins = pkgs.vimPlugins // pkgs.callPackage ./custom-plugins.nix {};
in {
programs.neovim = {
# ...
configure = {
customRC = builtins.readFile ./vimrc;
plug.plugins = with plugins; [
# Themes
onedark-vim
# ...
];
};
};
} See this file in action here: https://github.com/rpearce/.config/blob/master/programs/neovim/default.nix |
Perhaps this was fixed with the merging of #792? |
I guess so, if people know how to make new vim plugins themselves? (I think I wouldn't by heart, and I'm not sure this is documented anywhere) |
Yeah, I'm sure the situation could improve in that area. There is some mention about how to add new plugins to Nixpkgs in the manual but I'm not sure about how to package plugins outside Nixpkgs. In any case, I believe that is an issue for https://github.com/NixOS/nixpkgs/ and not this repo. |
Yes, good point. |
This issue has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/vim-plugin-not-available-on-my-system-but-it-is-in-nixpkgs/11723/1 |
How do I best install vim plugins that aren't listed by
nix-env -f '<nixpkgs>' -qaP -A vimPlugins
? Is it possible to usevam
orpathogen
?The text was updated successfully, but these errors were encountered: