programs/editors/helix: add helix editor

This commit is contained in:
Anthony Rodriguez 2024-10-14 17:23:36 +02:00
parent 0e08d243d1
commit 29bd2ab5b8
Signed by: nezia
GPG key ID: EE3BE97C040A86CE
2 changed files with 42 additions and 0 deletions

View file

@ -14,5 +14,6 @@
"${self}/home/terminal/emulators/foot.nix"
"${self}/home/programs/editors/neovim.nix"
"${self}/home/programs/editors/helix.nix"
];
}

View file

@ -0,0 +1,41 @@
{
lib,
pkgs,
...
}: let
inherit (lib) getExe;
in {
programs.helix = {
enable = true;
settings = {
theme = "catppuccin_macchiato";
editor = {
line-number = "relative";
lsp.display-messages = true;
auto-format = true;
auto-completion = true;
completion-timeout = 5;
};
keys.normal = {
space = {
space = "file_picker";
w = ":w";
q = ":q";
};
esc = ["collapse_selection" "keep_primary_selection"];
};
};
languages = {
language = [
{
name = "nix";
formatter = {command = getExe pkgs.alejandra;};
}
];
};
};
home.packages = [
pkgs.nil
];
}