mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
one: init colorscheme
This commit is contained in:
parent
d3252f7be8
commit
c3fc078107
3 changed files with 28 additions and 4 deletions
|
@ -195,13 +195,14 @@ in
|
||||||
});
|
});
|
||||||
|
|
||||||
configure = {
|
configure = {
|
||||||
customRC = ''
|
customRC = cfg.extraConfigVim + (optionalString (cfg.colorscheme != "") ''
|
||||||
|
colorscheme ${cfg.colorscheme}
|
||||||
|
'') + ''
|
||||||
lua <<EOF
|
lua <<EOF
|
||||||
${cfg.extraConfigLua}
|
${cfg.extraConfigLua}
|
||||||
EOF
|
EOF
|
||||||
'' + cfg.extraConfigVim + (optionalString (cfg.colorscheme != "") ''
|
'';
|
||||||
colorscheme ${cfg.colorscheme}
|
|
||||||
'');
|
|
||||||
packages.nixvim = {
|
packages.nixvim = {
|
||||||
start = filter (f: f != null) (map (x:
|
start = filter (f: f != null) (map (x:
|
||||||
if x ? plugin && x.optional == true then null else (x.plugin or x))
|
if x ? plugin && x.optional == true then null else (x.plugin or x))
|
||||||
|
|
22
plugins/colorschemes/one.nix
Normal file
22
plugins/colorschemes/one.nix
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
{ pkgs, config, lib, ... }:
|
||||||
|
with lib;
|
||||||
|
let
|
||||||
|
cfg = config.programs.nixvim.colorschemes.one;
|
||||||
|
in {
|
||||||
|
options = {
|
||||||
|
programs.nixvim.colorschemes.one = {
|
||||||
|
enable = mkEnableOption "Enable vim-one";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
programs.nixvim = {
|
||||||
|
colorscheme = "one";
|
||||||
|
extraPlugins = [ pkgs.vimPlugins.vim-one ];
|
||||||
|
|
||||||
|
options = {
|
||||||
|
termguicolors = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -2,6 +2,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
./colorschemes/gruvbox.nix
|
./colorschemes/gruvbox.nix
|
||||||
./colorschemes/onedark.nix
|
./colorschemes/onedark.nix
|
||||||
|
./colorschemes/one.nix
|
||||||
./colorschemes/base16.nix
|
./colorschemes/base16.nix
|
||||||
|
|
||||||
./statuslines/lightline.nix
|
./statuslines/lightline.nix
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue