mirror of
https://github.com/Matir/skel.git
synced 2026-05-25 21:19:09 -07:00
Install oh-my-zsh if possible.
This commit is contained in:
12
install.sh
12
install.sh
@@ -10,6 +10,17 @@ if [ ! -d $BASEDIR ] ; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
function prerequisites {
|
||||
if which zsh > /dev/null ; then
|
||||
chsh -s `which zsh`
|
||||
if [ ! -d $HOME/.oh-my-zsh ] ; then
|
||||
git clone https://github.com/robbyrussell/oh-my-zsh.git $HOME/.oh-my-zsh
|
||||
fi
|
||||
else
|
||||
echo "ZSH not found!" > /dev/stderr
|
||||
fi
|
||||
}
|
||||
|
||||
function install_dir {
|
||||
SRCDIR="${1}"
|
||||
find ${SRCDIR} \( -name .git -o \
|
||||
@@ -24,5 +35,6 @@ function install_dir {
|
||||
done
|
||||
}
|
||||
|
||||
prerequisites
|
||||
install_dir "${BASEDIR}"
|
||||
test -d "${BASEDIR}/private_dotfiles" && install_dir "${BASEDIR}/private_dotfiles"
|
||||
|
||||
Reference in New Issue
Block a user