[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SEUL: Simple whiptail script
Here is a simple whiptail script that serves simply as an introduction
using the syntax for a yes/no box. Whiptail still has a (to me) serious
bug in that you can not assign dialog strings to variables. You must code
the whole text into the string each time you use it. This gets tiresome
and wastes space if you keep the same backtitle for all your boxes.
#! /bin/bash
if (whiptail --title "PPP Configuration" --backtitle "Welcome to SEUL" --yesno "
Do you want to configure your PPP connection?" 10 40 )
then
echo -e "\nWell, you better get busy!\n"
elif (whiptail --title "PPP Configuration" --backtitle "Welcome to
SEUL" --yesno " Are you sure?" 7 40)
then
echo -e "\nGood, because I can't do that yet!\n"
else
echo -e "\nToo bad, I can't do that yet\n"
fi
George Bonser
If NT is the answer, you didn't understand the question. (NOTE: Stolen sig)
http://www.debian.org
Debian/GNU Linux ... the maintainable operating system.