I have a bash script I'm working on to help with an installer. why doesn't this work?
function fn_myFunc(){
local MYVAR=0
until ["$MYVAR" -ne 0]; do
whiptail --yesno "Yes or No?" --no-button "No" --yes-button "Yes" 10 70
MYVAR=$?
echo $MYVAR
done
}
This code loops infinitely, even though if Yes is selected, the echo $MYVAR
prints out 0 and it prints 1 if no is selected.
man bash
of course, maybe also Bash Hackers or Advanced Bash Scripting Guide. – choroba Nov 26 '14 at 14:19