Refactor directory structure
This commit is contained in:
9
modules/home/cli/common/default.nix
Normal file
9
modules/home/cli/common/default.nix
Normal file
@@ -0,0 +1,9 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./git.nix
|
||||
./shell.nix
|
||||
./helix.nix
|
||||
];
|
||||
}
|
23
modules/home/cli/common/git.nix
Normal file
23
modules/home/cli/common/git.nix
Normal file
@@ -0,0 +1,23 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.lazygit = {
|
||||
enable = true;
|
||||
settings = {
|
||||
services = {
|
||||
"gitea.xeovalyte.dev" = "gitea:gitea.xeovalyte.dev";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
programs.git = {
|
||||
enable = true;
|
||||
userEmail = "me+gitea@xeovalyte.dev";
|
||||
userName = "xeovalyte";
|
||||
extraConfig = {
|
||||
commit.gpgsign = true;
|
||||
gpg.format = "ssh";
|
||||
user.signingkey = "~/.ssh/gitea.pub";
|
||||
};
|
||||
};
|
||||
}
|
113
modules/home/cli/common/helix.nix
Normal file
113
modules/home/cli/common/helix.nix
Normal file
@@ -0,0 +1,113 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
programs.helix = {
|
||||
enable = true;
|
||||
package = pkgs.unstable.helix;
|
||||
defaultEditor = true;
|
||||
settings = {
|
||||
theme = "base16";
|
||||
editor.cursor-shape = {
|
||||
insert = "bar";
|
||||
};
|
||||
};
|
||||
languages = {
|
||||
language-server.rust-analyzer.config = {
|
||||
cargo = {
|
||||
features = "all";
|
||||
};
|
||||
};
|
||||
};
|
||||
themes = {
|
||||
base16 = let
|
||||
base00 = "#${config.colorScheme.palette.base00}";
|
||||
base01 = "#${config.colorScheme.palette.base01}";
|
||||
base02 = "#${config.colorScheme.palette.base02}";
|
||||
base03 = "#${config.colorScheme.palette.base03}";
|
||||
base04 = "#${config.colorScheme.palette.base04}";
|
||||
base05 = "#${config.colorScheme.palette.base05}";
|
||||
base06 = "#${config.colorScheme.palette.base06}";
|
||||
base07 = "#${config.colorScheme.palette.base07}";
|
||||
base08 = "#${config.colorScheme.palette.base08}";
|
||||
base09 = "#${config.colorScheme.palette.base09}";
|
||||
base0A = "#${config.colorScheme.palette.base0A}";
|
||||
base0B = "#${config.colorScheme.palette.base0B}";
|
||||
base0C = "#${config.colorScheme.palette.base0C}";
|
||||
base0D = "#${config.colorScheme.palette.base0D}";
|
||||
base0E = "#${config.colorScheme.palette.base0E}";
|
||||
base0F = "#${config.colorScheme.palette.base0F}";
|
||||
in {
|
||||
"attributes" = base09;
|
||||
"comment" = { fg = base03; modifiers = ["italic"]; };
|
||||
"constant" = base09;
|
||||
"constant.character.escape" = base0C;
|
||||
"constant.numeric" = base09;
|
||||
"constructor" = base0D;
|
||||
"debug" = base03;
|
||||
"diagnostic" = { modifiers = ["underlined"]; };
|
||||
"diff.delta" = base09;
|
||||
"diff.minus" = base08;
|
||||
"diff.plus" = base0B;
|
||||
"error" = base08;
|
||||
"function" = base0D;
|
||||
"hint" = base03;
|
||||
"info" = base0D;
|
||||
"keyword" = base0E;
|
||||
"label" = base0E;
|
||||
"namespace" = base0E;
|
||||
"operator" = base05;
|
||||
"special" = base0D;
|
||||
"string" = base0B;
|
||||
"type" = base0A;
|
||||
"variable" = base08;
|
||||
"variable.other.member" = base0B;
|
||||
"warning" = base09;
|
||||
|
||||
"markup.bold" = { fg = base0A; modifiers = ["bold"]; };
|
||||
"markup.heading" = base0D;
|
||||
"markup.italic" = { fg = base0E; modifiers = ["italic"]; };
|
||||
"markup.link.text" = base08;
|
||||
"markup.link.url" = { fg = base09; modifiers = ["underlined"]; };
|
||||
"markup.list" = base08;
|
||||
"markup.quote" = base0C;
|
||||
"markup.raw" = base0B;
|
||||
"markup.strikethrough" = { modifiers = ["crossed_out"]; };
|
||||
|
||||
"diagnostic.hint" = { underline = { style = "curl"; }; };
|
||||
"diagnostic.info" = { underline = { style = "curl"; }; };
|
||||
"diagnostic.warning" = { underline = { style = "curl"; }; };
|
||||
"diagnostic.error" = { underline = { style = "curl"; }; };
|
||||
|
||||
# "ui.background" = { bg = base00; };
|
||||
"ui.bufferline.active" = { fg = base00; bg = base03; modifiers = ["bold"]; };
|
||||
"ui.bufferline" = { fg = base04; bg = base00; };
|
||||
"ui.cursor" = { fg = base0A; modifiers = ["reversed"]; };
|
||||
"ui.cursor.insert" = { fg = base0A; modifiers = ["reversed"]; };
|
||||
"ui.cursorline.primary" = { fg = base05; bg = base01; };
|
||||
"ui.cursor.match" = { fg = base0A; modifiers = ["reversed"]; };
|
||||
"ui.cursor.select" = { fg = base0A; modifiers = ["reversed"]; };
|
||||
"ui.gutter" = { bg = base00; };
|
||||
"ui.help" = { fg = base06; bg = base01; };
|
||||
"ui.linenr" = { fg = base03; bg = base00; };
|
||||
"ui.linenr.selected" = { fg = base04; bg = base01; modifiers = ["bold"]; };
|
||||
"ui.menu" = { fg = base05; bg = base01; };
|
||||
"ui.menu.scroll" = { fg = base03; bg = base01; };
|
||||
"ui.menu.selected" = { fg = base01; bg = base04; };
|
||||
"ui.popup" = { bg = base01; };
|
||||
"ui.selection" = { bg = base02; };
|
||||
"ui.selection.primary" = { bg = base02; };
|
||||
"ui.statusline" = { fg = base04; bg = base01; };
|
||||
"ui.statusline.inactive" = { bg = base01; fg = base03; };
|
||||
"ui.statusline.insert" = { fg = base00; bg = base0B; };
|
||||
"ui.statusline.normal" = { fg = base00; bg = base03; };
|
||||
"ui.statusline.select" = { fg = base00; bg = base0F; };
|
||||
"ui.text" = base05;
|
||||
"ui.text.focus" = base05;
|
||||
"ui.virtual.indent-guide" = { fg = base03; };
|
||||
"ui.virtual.inlay-hint" = { fg = base01; };
|
||||
"ui.virtual.ruler" = { bg = base01; };
|
||||
"ui.window" = { bg = base01; };
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
40
modules/home/cli/common/shell.nix
Normal file
40
modules/home/cli/common/shell.nix
Normal file
@@ -0,0 +1,40 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
eza
|
||||
bat
|
||||
];
|
||||
|
||||
home.shellAliases = {
|
||||
ls = "eza";
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
enableBashIntegration = true;
|
||||
};
|
||||
|
||||
programs.zellij = {
|
||||
enable = true;
|
||||
# enableBashIntegration = true;
|
||||
};
|
||||
|
||||
home.file.zellij = {
|
||||
target = ".config/zellij/config.kdl";
|
||||
text = ''
|
||||
pane_frames false
|
||||
default_layout "compact"
|
||||
keybinds {
|
||||
normal {
|
||||
bind "Ctrl e" { ToggleFloatingPanes; SwitchToMode "normal"; }
|
||||
}
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
}
|
Reference in New Issue
Block a user