From 7bb8787b714651be2c269dee94af935fb39312e0 Mon Sep 17 00:00:00 2001 From: Rodolphe Breard Date: Tue, 20 Oct 2015 13:35:06 +0200 Subject: [PATCH] Checking if xscreensaver is installed before creating the lock alias. --- .zshrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.zshrc b/.zshrc index c91f202..909b64b 100644 --- a/.zshrc +++ b/.zshrc @@ -60,7 +60,7 @@ alias grep='grep -n --color=auto' alias j='jobs' alias df='df -h' alias du='du -ch' -alias lock='xscreensaver-command --lock' +hash xscreensaver-command 2>/dev/null && alias lock='xscreensaver-command --lock' hash sqlmap 2>/dev/null && alias sqlmap='sqlmap --user-agent="Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"' hash sqlmap 2>/dev/null && alias sqlmap-tor='sqlmap --tor --tor-type=SOCKS5' hash steam 2>/dev/null && alias steam='find ~/.steam/root/ \( -name "libgcc_s.so*" -o -name "libstdc++.so*" -o -name "libxcb.so*" \) -print -delete; steam'