zsh: Add alias for rebuild-switch

This commit is contained in:
PapaTutuWawa 2021-12-06 23:04:27 +01:00
parent e3046029df
commit e112c9f5ee

View File

@ -21,7 +21,10 @@ in {
home-manager.users."${config.ptw.system.singleUser}".programs.zsh = {
enable = true;
history.ignoreSpace = true;
shellAliases = {
shellAliases = let
home = "/home/${config.ptw.system.singleUser}/Development/Personal/nixos-config";
nixosSwitch = "nixos-rebuild --flake .#${config.ptw.system.hostName} switch";
in {
ls = "ls --color=always";
".." = "cd ..";
"..." = "cd ../../";
@ -33,6 +36,8 @@ in {
gds = "git diff --staged";
c = "clear";
suspend = "systemctl suspend";
nixos-rebuild-switch = "pushd; cd ${home}; sudo ${nixosSwitch}; popd";
nixos-rebuild-switch-fast = "pushd; cd ${home}; sudo ${nixosSwitch} --fast; popd";
waifu2x = "flatpak run com.github.nihui.waifu2x-ncnn-vulkan";
};