Fix hx function
parent
25e6aecd5c
commit
b18d15a62c
|
@ -27,19 +27,15 @@ in
|
||||||
"helix/dark.toml".source = tomlFormat.generate "helix-autotheme" (cfg.settings // { theme = extras.autoTheme.dark; });
|
"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 = {
|
programs.fish.functions = {
|
||||||
hx = {
|
hx = {
|
||||||
|
wraps = "hx";
|
||||||
description = "Helix invocation wrapper to automatically select the right theme";
|
description = "Helix invocation wrapper to automatically select the right theme";
|
||||||
body = ''
|
body = ''
|
||||||
if is-dark-mode
|
if is-dark-mode
|
||||||
hxd $argv
|
command hx --config ${config.xdg.configHome}/helix/dark.toml $argv
|
||||||
else
|
else
|
||||||
hxl $argv
|
command hx --config ${config.xdg.configHome}/helix/light.toml $argv
|
||||||
end
|
end
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue