Skip to content

Commit

Permalink
Update colorize.plugin.zsh
Browse files Browse the repository at this point in the history
correctly detect when pygmentize is not installed
do not exit shell if when pygmentize is not installed
  • Loading branch information
cbliard authored and ncanceill committed May 29, 2014
1 parent 3fac127 commit 3c41da3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions plugins/colorize/colorize.plugin.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
alias colorize='colorize_via_pygmentize'

colorize_via_pygmentize() {
if [ ! -x $(which pygmentize) ]; then
echo package \'pygmentize\' is not installed!
exit -1
if [ ! -x "$(which pygmentize)" ]; then
echo "package \'pygmentize\' is not installed!"
return -1
fi

if [ $# -eq 0 ]; then
Expand Down

0 comments on commit 3c41da3

Please sign in to comment.