Introduction Zenity simple GUI for Bash

Share this post to your friends !

This entry is part 1 of 13 in the series GUI for bash script using Zenity

WriteBash - In this article, I will introduce to you about zenity software – a tool that allows you to create simple GUi for bash scripts. The Zenity tool has a fairly simple command structure, and I’ll talk about those commands in later articles.

What is Zenity?

First, Zenity is a completely free cross-platform program. It allows you to create GTK + dialogs via command lines and shell scripts.

Zenity was originally developed by Sun Microsystems (I’ve read somewhere about this, probably on Wikipedia). Zenith is continuing to grow and operate with the maintainers LuisMedinas and ArxCruz.

This program can run cross platform on both Linux, Windows and Mac OSX. However, I see zenity only used on Linux is mainly. Zenity Homepage.

introduction-zenity-simple-gui-for-bash Introduction Zenity simple GUI for Bash
About zenity

Install zenity

Zenity is installed by default or is available in the repositories of the current standard Linux operating system.

To check program zenity have on your pc or not, you run the following command:

zenity --version

If the above command does not produce results as like this:

root@writebash ~ # zenity --version

You can install zenity on Linux through the following command.

  • For operating systems based on Debian (or Ubuntu):
sudo apt-get install zenity -y
  • For operating systems based on RedHat (or Fedora):
sudo yum install zenity -y

To display all the Zenity commands, type:

zenity --help

Create GUI for Bash, why is Zenity?

Personally, I or you will find that language Bash is not a powerful language for programming graphical user interface.

Most of the current applications written with the language are strong and flexible such as: C, Java, Python.

Why is Zenity? The answer is very simple. This is because Zenity is very simple and it fully supports Bash scripts. However, Zenity’s versatility is not as good as professional GUI design tools.


In the next article, I will talk more about each type of dialog that Zenity supports. And at the end of this series about Zenity, I will guide you to write a small program completed using Zenity and Bash.

Continue reading the seriesNext part: Bash create calendar dialog with Zenity »»
If you liked this article, then please subscribe to our YouTube Channel for more video tutorials. You can also find us on Twitter and Facebook.

Share this post to your friends !
If you appreciate what we share in this blog, you can support us by:
  1. Stay connected to: Facebook | Twitter | Google Plus | YouTube
  2. Subscribe email to recieve new posts from us: Sign up now.
  3. Start your own blog with SSD VPS - Free Let's Encrypt SSL ($2.5/month).
  4. Become a Supporter - Make a contribution via PayPal.
  5. Support us by purchasing Ribbon Lite Child theme being using on this website.

We are thankful for your support.

single post bottom banner
«« »»

Got something to say? Join the discussion

Please keep in mind that all comments are subject to our Comment Policy. Your email address will not be published.
This site uses Akismet to reduce spam. Learn how your comment data is processed.