mirror of
https://github.com/CHN-beta/nixos.git
synced 2024-10-22 23:18:44 +08:00
modules.package.helix: init
This commit is contained in:
parent
319c3b227c
commit
c64b905cb3
17
modules/packages/helix.nix
Normal file
17
modules/packages/helix.nix
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
inputs:
|
||||||
|
{
|
||||||
|
options.nixos.packages.helix = let inherit (inputs.lib) mkOption types; in mkOption
|
||||||
|
{ type = types.nullOr (types.submodule {}); default = {}; };
|
||||||
|
config = let inherit (inputs.config.nixos.packages) helix; in inputs.lib.mkIf (helix != null)
|
||||||
|
{
|
||||||
|
nixos.user.sharedModules =
|
||||||
|
[{
|
||||||
|
config.programs.helix =
|
||||||
|
{
|
||||||
|
enable = true;
|
||||||
|
defaultEditor = true;
|
||||||
|
settings.theme = "catppuccin_latte";
|
||||||
|
};
|
||||||
|
}];
|
||||||
|
};
|
||||||
|
}
|
@ -1,30 +0,0 @@
|
|||||||
inputs:
|
|
||||||
{
|
|
||||||
options.nixos.packages.vim = let inherit (inputs.lib) mkOption types; in mkOption
|
|
||||||
{ type = types.nullOr (types.submodule {}); default = {}; };
|
|
||||||
config = let inherit (inputs.config.nixos.packages) vim; in inputs.lib.mkIf (vim != null)
|
|
||||||
{
|
|
||||||
nixos.user.sharedModules =
|
|
||||||
[{
|
|
||||||
config.programs.vim =
|
|
||||||
{
|
|
||||||
enable = true;
|
|
||||||
defaultEditor = true;
|
|
||||||
packageConfigurable = inputs.config.programs.vim.package;
|
|
||||||
settings =
|
|
||||||
{
|
|
||||||
number = true;
|
|
||||||
expandtab = false;
|
|
||||||
shiftwidth = 2;
|
|
||||||
tabstop = 2;
|
|
||||||
};
|
|
||||||
extraConfig =
|
|
||||||
''
|
|
||||||
set clipboard=unnamedplus
|
|
||||||
colorscheme evening
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}];
|
|
||||||
programs.vim.package = inputs.pkgs.vim-full;
|
|
||||||
};
|
|
||||||
}
|
|
@ -8,7 +8,7 @@ inputs:
|
|||||||
package = inputs.pkgs.gitFull;
|
package = inputs.pkgs.gitFull;
|
||||||
extraConfig =
|
extraConfig =
|
||||||
{
|
{
|
||||||
core.editor = if inputs.config.nixos.system.gui.preferred then "code --wait" else "vim";
|
core.editor = "hx";
|
||||||
http.postBuffer = 624288000;
|
http.postBuffer = 624288000;
|
||||||
advice.detachedHead = false;
|
advice.detachedHead = false;
|
||||||
merge.conflictstyle = "diff3";
|
merge.conflictstyle = "diff3";
|
||||||
|
Loading…
Reference in New Issue
Block a user