Tutorial :Tool to create UI for Linux (Gnome) shell scripts



Question:

I'm writing a bunch of Linux shell scripts with complex selections. For now I use zenity for prompts. I'd rather use something where I can show more than one UI element at a time and query it in a script (e.g. a list and some checkboxed and a file picker and an entry field. What are my options?


Solution:1

I believe GTKDialog comes with extended gtk-ified versions of the popular curses based dialog utility for shell scripts.

I'm not sure if it will serve the complexity of your needs, however. In any event, its a place to start.


Solution:2

You're going to have to move up to something more capable. PyGTK with Glade is fairly powerful, and Python is easy enough to pick up.


Solution:3

autoglade could also be of help to give your scripts of commands a graphical user interface, in many cases with no additional programming.

Some docs and tutorials can be found here.


Solution:4

zenity 3 now has a option to create a form with multiple elements. See the following bug report

https://bugzilla.gnome.org/show_bug.cgi?id=412493


Solution:5

Yad is a fork of Zenity that adds almost as much functionality as Gtkdialog. Mostly backward compatible too.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »