Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Switch GNOME Terminal Profile from the command line

If I'm running gnome-terminal with multiple tabs open, is it possible to switch the profile of a given tab at the bash prompt, with instant effect, and without altering the profile of the other tabs?

I understand how to use gconftool or gconftool-2 to change elements of a profile (such as the background), but I don't know how to actually switch the profile for a specific tab or window.

Any advice is appreciated.

like image 954
Hackett Avatar asked Mar 18 '09 23:03

Hackett


People also ask

How do I change GNOME Terminal?

To configure GNOME terminal, go to Edit > Preferences. From here, you can configure some global and profile specific settings of GNOME Terminal.

Where is GNOME Terminal profile?

These distributions utilize Gnome-terminal, and provide flexible ways to set up different terminal profiles via a drop down menu located in the terminal window, directly above where commands are, usually, entered. These profiles allow making changes to the font and color properties of different files etc..

How do I change the default profile in terminal?

Configure your default profile by running the Terminal: Select Default Profile command, which is also accessible via the new terminal dropdown. The default terminal profile shell defaults to $SHELL on Linux and macOS and PowerShell on Windows.

How do I open terminal gnome from terminal?

To quickly open a Terminal window at any time, press Ctrl+Alt+T. A graphical GNOME Terminal window will pop right up.


1 Answers

It does not answer your question in particular, but since it might help others, I leave it here regardless.

If there was a way to change the current profile, you could have different profiles for each tab.

You can list all existing profiles using:

gconftool-2 --all-dirs /apps/gnome-terminal/profiles

You can get the current profile using:

gconftool-2 --get /apps/gnome-terminal/global/default_profile

And you can set a new default profile (solarized-light in this case) using:

gconftool-2 --set --type string /apps/gnome-terminal/global/default_profile solarized-light
like image 69
2 revs, 2 users 97% Avatar answered Oct 23 '22 03:10

2 revs, 2 users 97%