Reputation: 6664
Using oh-my-zsh, I've got the following at the bottom of .zshrc
:
fortune | xargs -0 cowsay | lolcat -a
When run from .zshrc
, it complains:
/Users/jorum/.zshrc:59: command not found: lolcat
Running it manually from the command line works:
➜ ~ fortune | xargs -0 cowsay | lolcat -a
<insert colorful cow saying something insightful here>
Leaving lolcat -a
out entirely also works (sans the colors of course).
Clearly, lolcat
isn't missing:
➜ ~ gem list lolcat
*** LOCAL GEMS ***
lolcat (42.0.99)
Why does it not work if executed from within .zshrc
?
Upvotes: 2
Views: 1882
Reputation: 6664
Moving the line in question to .zlogin
fixed the problem.
More specifically, I had to move it below this line that was added by RVM:
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
Upvotes: 3