diff --git a/modules/home/programs/helix/extras.nix b/modules/home/programs/helix/extras.nix index aef2888..3a5c61f 100644 --- a/modules/home/programs/helix/extras.nix +++ b/modules/home/programs/helix/extras.nix @@ -27,19 +27,15 @@ in "helix/dark.toml".source = tomlFormat.generate "helix-autotheme" (cfg.settings // { theme = extras.autoTheme.dark; }); }; - programs.fish.shellAbbrs = { - hxl = "${cfg.package} --config ${config.xdg.configHome}/helix/light.toml"; - hxd = "${cfg.package} --config ${config.xdg.configHome}/helix/dark.toml"; - }; - programs.fish.functions = { hx = { + wraps = "hx"; description = "Helix invocation wrapper to automatically select the right theme"; body = '' if is-dark-mode - hxd $argv + command hx --config ${config.xdg.configHome}/helix/dark.toml $argv else - hxl $argv + command hx --config ${config.xdg.configHome}/helix/light.toml $argv end ''; };