tags:

views:

57

answers:

4

Hi,

In Ubuntu Server 10.04

Sometimes when i'm installing some packages through apt-get, it prompts me with a blue dialog and asks for input/selection.. E.G: when installing mysql-server, it prompts me for a root password.. How can i accomplish this in my own shell script, so that same blue dialog will show up when i need to ask yes/no and password questions?

A: 

http://tldp.org/HOWTO/Bash-Prompt-HOWTO/x329.html

Don't be afraid to Google something first ;)

Glenn Nelson
That is not what the OP is asking for.
Amber
This is not what i was needing, but thanks anyway, PS I did google first, but couldn't find anything
Daniel
+2  A: 

You're looking for dialog.

Ignacio Vazquez-Abrams
+1  A: 

Try the ncurses library.

http://www.gnu.org/software/ncurses/

There are some examples of using ncurses stuff (including dialog, which is what's probably being used in your examples) from bash here:

http://subsignal.org/doc/AliensBashTutorial.html

Amber
+3  A: 

Check tutorials for dialog here and here.

Tarantula