home: Split off and extend editor configuration

This commit is contained in:
Mikael 2024-08-28 13:14:34 +02:00
parent 06d0480181
commit d9f775a364
Signed by: mikael
SSH key fingerprint: SHA256:21QyD2Meiot7jOUVitIR5YkGB/XuXdCvLW1hE6dsri0
2 changed files with 63 additions and 34 deletions

View file

@ -0,0 +1,62 @@
{ ... }: { config, lib, ... }: {
programs.helix = {
enable = true;
defaultEditor = true;
settings = {
editor.auto-pairs = {
"" = "";
"" = "";
"" = "";
"" = "";
};
editor.whitespace.render = {
nbsp = "all";
nnbsp = "all";
tab = "all";
};
editor.whitespace.characters = {
nbsp = "";
nnbsp = "";
tab = "»";
tabpad = "·";
};
keys.normal = {
minus = "command_mode";
r = "move_char_left";
n = "move_visual_line_down";
t = "move_visual_line_up";
h = "move_char_right";
p = "move_prev_word_start";
w = "move_next_word_start";
l = "move_next_word_end";
P = "move_prev_long_word_start";
W = "move_next_long_word_start";
L = "move_next_long_word_end";
z = "replace";
Z = "zeplace_with_yanked";
s = "paste_after";
S = "paste_before";
x = "extend_line_below";
X = "extend_to_line_bounds";
Alt-X = "shrink_to_link_bounds";
e = "change_selection";
Alt-e = "change_selection_noyank";
N = "join_selections";
Alt-N = "join_selections_space";
semicolon = "search_next";
colon = "search_prev";
};
};
};
}

View file

@ -15,6 +15,7 @@ in {
./gammarelay.nix
./founts.nix
./stylix.nix
./editor.nix
./desktop.nix
./bar.nix
./terminal.nix
@ -204,40 +205,6 @@ in {
};
};
programs.helix = {
enable = true;
defaultEditor = true;
settings = {
editor.auto-pairs = {
"" = "";
"" = "";
"" = "";
"" = "";
};
editor.whitespace.render = {
nbsp = "all";
nnbsp = "all";
tab = "all";
};
editor.whitespace.characters = {
nbsp = "";
nnbsp = "";
tab = "»";
tabpad = "·";
};
keys.normal = {
minus = "command_mode";
r = "move_char_left";
n = "move_visual_line_down";
t = "move_visual_line_up";
h = "move_char_right";
};
};
};
programs.jq.enable = true;
programs.man.generateCaches =
osConfig.documentation.man.generateCaches or false;