diff --git a/home/apps/cli.nix b/home/apps/cli.nix index 48748ab..d35d701 100644 --- a/home/apps/cli.nix +++ b/home/apps/cli.nix @@ -8,7 +8,14 @@ in sessionVariables = { LESS = "-R --use-color"; LESSHISTFILE = "-"; - MANPAGER = "sh -c 'col -bx | bat -l man -p'"; + }; + shellAliases = { + # switch between yubikeys for the same GPG key + switch_yubikeys = ''gpg-connect-agent "scd serialno" "learn --force" "/bye"''; + + # podman + docker = "podman"; + docker-compose = "podman-compose"; }; }; diff --git a/home/apps/nu.nix b/home/apps/nu.nix index 387efc9..cab5540 100644 --- a/home/apps/nu.nix +++ b/home/apps/nu.nix @@ -1,7 +1,16 @@ -{ lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: let plugins = "${pkgs.nu_scripts}/share/nu_scripts"; + shellAliases = lib.concatStringsSep "\n" ( + lib.mapAttrsToList (k: v: "alias ${k} = ${v}") config.home.shellAliases + ); + mkCompletions = completions: lib.concatStringsSep "\n" ( @@ -49,6 +58,7 @@ in '' source ${plugins}/aliases/git/git-aliases.nu '' + + shellAliases + mkCompletions completions; }; diff --git a/home/apps/zsh.nix b/home/apps/zsh.nix index 8ed6090..d2808fa 100644 --- a/home/apps/zsh.nix +++ b/home/apps/zsh.nix @@ -88,6 +88,9 @@ in file = "share/zsh/site-functions/fast-syntax-highlighting.plugin.zsh"; } ]; + sessionVariables = { + MANPAGER = "sh -c 'col -bx | bat -l man -p'"; + }; shellAliases = { cat = "bat"; @@ -101,13 +104,6 @@ in cp = "cp -i"; mv = "mv -i"; rm = "rm -i"; - - # switch between yubikeys for the same GPG key - switch_yubikeys = ''gpg-connect-agent "scd serialno" "learn --force" "/bye"''; - - # podman - docker = "podman"; - docker-compose = "podman-compose"; }; history.path = "${config.xdg.configHome}/zsh/history"; };