How to determine which theme is currently enabled using the terminal? (GNOME)

Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"

Hi, folks. This post although simple to use and explain can help us more than once. Especially in scripting and customization settings. Today, you will learn how to determine which theme is currently enabled using the terminal on Ubuntu | Linux Mint

Is it really useful?

The reality is that how useful you can find this will depend on how you use the system or what you are doing. Knowing how to manipulate your system from the terminal allows you to create configuration scripts that help determine the settings you want.

Moreover, you can learn even more about the system with these new features. So, it’s always a good idea to have these tricks on hand.

Let’s get started.

Determine which theme is currently enabled using the terminal on Ubuntu | Linux Mint

The best way to do this is with gsettings which, in a GNOME or GNOME-derived environment like Cinnamon, you can manipulate the desktop environment options. In addition, of course, you can use it to check options.

So, to find out which theme is enabled, you can open a terminal and run this command

gsettings get org.gnome.desktop.interface gtk-theme

You should get an output screen like the following

Theme currently enabled
Theme currently enabled

Although the screenshot is from Linux Mint, it works with Ubuntu and derivatives like POP_OS!

Check the available themes using the terminal

As a bonus, we will explain how to get the available themes using the terminal. The themes are present in these two directories.

  • /usr/share/themes
  • ~/.themes

It would be enough to use the ls command

ls /usr/share/themes

Or:

ls ~/.themes

And the output on the screen will be folders where the theme files are.

.
.
.
Flat-Remix-GTK-Blue
Flat-Remix-GTK-Blue-Dark
Flat-Remix-GTK-Blue-Darker
Flat-Remix-GTK-Blue-Darker-Solid  .
.
.
.

Finally, if you want to set a new theme using the terminal, you can do it as follows

gsettings set org.gnome.desktop.interface gtk-theme [theme]

Where you will have to replace [theme] with the name of the theme as specified in the folder.

That’s how simple it is to do it.

Conclusion

Knowing the system in the terminal is vital to do anything with it. So today you know how to know the current system theme and even how to list and apply them all from the terminal.

Everything Linux, A.I, IT News, DataOps, Open Source and more delivered right to you.
Subscribe
"The best Linux newsletter on the web"
Angelo
Angelo
I am Angelo. A systems engineer passionate about Linux and all open-source software. Although here I'm just another member of the family.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest articles

Join us on Facebook