I'm a bash newbie.
- How to make whiptail full terminal screen? "as big as the terminal", like fluid CSS
- Say I have this script
#!/bin/bash
function cpp-lang {
yum install "Development Tools"
}
function updatesys {
yum -y update yum -y upgrade
}
whiptail --checklist "test" 5 40 5\
Update "Update the system" on \
C++ "Install C++" off 2>results
while read choice
do
case $choice in
Update )updatesys
;;
C++)cpp-lang
;;
*)
;;
esac
done < results
When I run it, it exists, should I return something from the function?
- Considering the script above as an example, should I run
sudo
everytime I callyum install
or is doingsudo ./script.sh
enough?
Aucun commentaire:
Enregistrer un commentaire