mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-12-12 20:21:02 +01:00
installer: don't bail on errors in color setup
This is a hack to keep the installer working on systems without tput/terminfo.
This commit is contained in:
parent
b05ef1034f
commit
f94fee5a7f
1 changed files with 5 additions and 2 deletions
|
@ -1,5 +1,3 @@
|
|||
set -e
|
||||
|
||||
# Use colors, but only if connected to a terminal, and that terminal
|
||||
# supports them.
|
||||
tput=$(which tput)
|
||||
|
@ -21,6 +19,11 @@ else
|
|||
BOLD=""
|
||||
NORMAL=""
|
||||
fi
|
||||
|
||||
# Only enable exit-on-error after the non-critical colorization stuff,
|
||||
# which may fail on systems lacking tput or terminfo
|
||||
set -e
|
||||
|
||||
CHECK_ZSH_INSTALLED=$(grep /zsh$ /etc/shells | wc -l)
|
||||
if [ ! $CHECK_ZSH_INSTALLED -ge 1 ]; then
|
||||
printf "${YELLOW}Zsh is not installed!${NORMAL} Please install zsh first!\n"
|
||||
|
|
Loading…
Reference in a new issue