add vim-airline

This commit is contained in:
Pedro Alves 2021-01-05 11:26:49 +00:00
parent 005df95e7b
commit 7122ccd208
9 changed files with 142 additions and 18 deletions

View file

@ -71,29 +71,17 @@ in {
description = "Mode name mappings";
default = null;
};
extraConfig = mkOption {
type = types.lines;
default = "";
description = "Extra configuration for this plugin";
};
};
};
config = let
configString = helpers.toVimDict {
configAttrs = {
inherit (cfg) colorscheme active component componentFunction modeMap;
};
in mkIf cfg.enable {
programs.nixvim = {
extraPlugins = [ pkgs.vimPlugins.lightline-vim ];
extraConfigVim = ''
""" lightline {{{
let g:lightline = ${configString}
${cfg.extraConfig}
""" }}}
'';
globals.lightline = configAttrs;
};
};
}