From 9f8a1c9f5010815e1875ae01df61bf62070ba99e Mon Sep 17 00:00:00 2001 From: Eric Torres Date: Mon, 9 Sep 2024 22:30:40 -0700 Subject: [PATCH] zsh-linux: only set autoremove alias in Arch --- zsh-linux/.config/zsh-linux/00-linux-aliases.zsh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zsh-linux/.config/zsh-linux/00-linux-aliases.zsh b/zsh-linux/.config/zsh-linux/00-linux-aliases.zsh index 727f61e..9600793 100644 --- a/zsh-linux/.config/zsh-linux/00-linux-aliases.zsh +++ b/zsh-linux/.config/zsh-linux/00-linux-aliases.zsh @@ -28,7 +28,7 @@ alias gr='git reset' #========= Package Management ========= # Arch Linux alias aurget='aur sync -d aur --chroot' -alias -g autoremove='pacman -Rns $(pacman -Qtdq)' +[[ -x $(which pacman) ]] && alias -g autoremove='pacman -Rns $(pacman -Qtdq)' alias checkaurupdates='aur sync -d aur --upgrades --chroot' # alias does not work correctly for some reason alias lspkg="pacman -Qi | awk '/^Name/{name=$3} /^Installed Size/{print $4$5, name}' | sort -h"