Fallbacks for the fortune display on logging in: just bail if fortune isn't available, and try alternatives if ponysay isn't available
This commit is contained in:
parent
c8f970cc1a
commit
109ca827b4
1 changed files with 3 additions and 1 deletions
|
@ -1,2 +1,4 @@
|
||||||
#! zsh
|
#! zsh
|
||||||
fortune $XDG_CACHE_HOME/sav-quotes/quotes | ponysay
|
(( $+commands[fortune] )) || return
|
||||||
|
for say in ponysay cowsay cat; (( $+commands[$say] )) && break
|
||||||
|
fortune $XDG_CACHE_HOME/sav-quotes/quotes | $say
|
||||||
|
|
Loading…
Reference in a new issue