mirror of
https://github.com/nix-community/home-manager
synced 2024-11-30 15:09:46 +01:00
eza: add xonsh integration
This commit is contained in:
parent
47a2dd4554
commit
b964ab7f39
1 changed files with 16 additions and 0 deletions
|
@ -37,6 +37,10 @@ with lib;
|
||||||
default = true;
|
default = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enableXonshIntegration = mkEnableOption "Xonsh integration" // {
|
||||||
|
default = true;
|
||||||
|
};
|
||||||
|
|
||||||
enableNushellIntegration = mkEnableOption "Nushell integration";
|
enableNushellIntegration = mkEnableOption "Nushell integration";
|
||||||
|
|
||||||
extraOptions = mkOption {
|
extraOptions = mkOption {
|
||||||
|
@ -97,6 +101,18 @@ with lib;
|
||||||
programs.ion.shellAliases = optionsAlias
|
programs.ion.shellAliases = optionsAlias
|
||||||
// optionalAttrs cfg.enableIonIntegration aliases;
|
// optionalAttrs cfg.enableIonIntegration aliases;
|
||||||
|
|
||||||
|
programs.xonsh.shellAliases = {
|
||||||
|
eza = [ "eza" ] ++ optional cfg.icons "--icons"
|
||||||
|
++ optional cfg.git "--git" ++ cfg.extraOptions;
|
||||||
|
} // optionalAttrs cfg.enableXonshIntegration
|
||||||
|
(builtins.mapAttrs (_name: value: lib.mkDefault value) {
|
||||||
|
ls = [ "eza" ];
|
||||||
|
ll = [ "eza" "-l" ];
|
||||||
|
la = [ "eza" "-a" ];
|
||||||
|
lt = [ "eza" "--tree" ];
|
||||||
|
lla = [ "eza" "-la" ];
|
||||||
|
});
|
||||||
|
|
||||||
programs.nushell.shellAliases = optionsAlias
|
programs.nushell.shellAliases = optionsAlias
|
||||||
// optionalAttrs cfg.enableNushellIntegration aliases;
|
// optionalAttrs cfg.enableNushellIntegration aliases;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue