1

Is there a command via which I can change the Terminal's background instead of doing so through the Edit -> Profile -> Edit -> Background pulldown?

4
  • It depends on your terminal emulator. Commented Jan 2, 2017 at 17:51
  • gnome terminal 3.6.2
    – Jon Snow
    Commented Jan 2, 2017 at 18:00
  • Best guess: you can't. Maybe you can modify your profile settings in ~/.gconf/apps/gnome-terminal/, but I don't think there's any way to make Gnome Terminal reload preferences on-the-fly. The reason I'm making a comment with a "guess" instead is because, unfortunately, Gnome Terminal no longer supports background images since version 3.8, so I can't even test it to see if what you're trying to do is at all possible.
    – giusti
    Commented Jan 2, 2017 at 19:13
  • ` gconftool-2 --type string --set /apps/gnome-terminal/profiles/Default/... ...`
    – JJoao
    Commented Jan 2, 2017 at 19:41

1 Answer 1

1

Try the code below and see if it suits your needs. In my Gnome it changes the background color in real time.

Note that it assumes you want the original profile; pick the profile you prefer from dconf dump / |grep legacy/profiles:/ |sed -r 's/^\[|\]$//g' and use profile=your_preferred_profile instead of the first line below.

profile="$(dconf dump / |grep legacy/profiles:/ |sed -r 's/^\[|\]$//g' |head -n1)"
dconf write /$profile/background-color "'rgb(50,50,50)'"
dconf write /$profile/foreground-color "'rgb(170,170,170)'"
dconf write /$profile/use-theme-colors false

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .