1
Fork 0
mirror of https://github.com/RGBCube/ncc synced 2025-07-31 20:17:45 +00:00

Set helix alias in helix.nix

This commit is contained in:
RGBCube 2024-01-16 14:27:26 +03:00
parent e293f31a45
commit 23ceb8e6a7
No known key found for this signature in database
2 changed files with 18 additions and 14 deletions

View file

@ -1,8 +1,24 @@
{ ulib, lib, pkgs, upkgs, ... }: with ulib; merge
(homeConfiguration {
programs.nushell.environmentVariables.EDITOR = "hx";
programs.nushell.shellAliases.x = "hx";
programs.nushell = {
environmentVariables.EDITOR = "hx";
shellAliases.x = "hx";
configFile.text = lib.mkAfter ''
def --wrapped hx [...arguments] {
if ($env.TERM | str contains "kitty") {
kitty @ set-spacing padding=0
}
^hx $arguments
if ($env.TERM | str contains "kitty") {
kitty @ set-spacing padding=${toString theme.padding}
}
}
'';
};
programs.helix = enabled {
languages.language = [

View file

@ -23,17 +23,5 @@ def --env mc [path: path] {
cd $path
}
def --wrapped hx [...arguments] {
if ($env.TERM | str contains "kitty") {
kitty @ set-spacing padding=0
}
^hx $arguments
if ($env.TERM | str contains "kitty") {
kitty @ set-spacing padding=${toString theme.padding}
}
}
use ${upkgs.nuScripts}/modules/background_task/task.nu
''