new logic for installing deps

This commit is contained in:
Stefen Auris 2019-10-07 11:59:29 -04:00
parent 218879e4a7
commit 712024dd5c
3 changed files with 35 additions and 2 deletions

11
init.sh
View file

@ -1,7 +1,14 @@
#!/bin/bash
#install pre-req.
echo "installing required packages"
bash deps.sh
echo -n "Which Linux flavor will we be installing programs for? (u/o)"; read answer
if [[ $answer = "U" ]] || [[ $answer = "u" ]]; then
bash udeps.sh
elif [[ $answer = "O" ]] || [[ $answer = "o" ]]; then
bash odeps.sh
else
echo "Aborting!"
exit 1
fi
#setup prezto
echo "Initializing Prezto"

26
odeps.sh Normal file
View file

@ -0,0 +1,26 @@
#!/bin/bash
#These are the programs I expect to find on any install
echo "installing base dependencies"
sudo zypper install git \
stow \
etckeeper \
tmux \
zsh \
vim \
powerline\
htop \
mc \
curl \
read -n1 -p $'Does this system need ssh access?\n' REPLY
if [[ $REPLY == [Yy] ]]; then
sudo zypper install openssh-server
fi
read -n1 -p $'\nDoes this system have a GUI?\n' REPLY
if [[ $REPLY == [Yy] ]]; then
sudo zypper install emacs
else
sudo zypper install emacs-nox
fi

View file