I am trying to write a bash script that modifies the default gnome-terminal profile (gnome 3). I have read that gsettings is the appropriate interface to use for this, but I can only seem to get the info I need using dconf.

Not understanding the difference between dconf and gsettings, I'd rather just use one interface fully, though I can get the job done with a half-understanding of either.

Can somebody tell me the equivalent gsettings command for this dconf one?

dconf read /org/gnome/terminal/legacy/profiles:/:8bb3f482-c55b-4d70-9c47-f2cf4254d5bf/visible-name

I was able to piece it together from the output of:

dconf dump /org/gnome/terminal/legacy/profiles:/

I think that if I know how it maps to gsettings I can puzzle out what I need from the gsettings help interface (I'll be sure to include an edit with whatever my misunderstanding was, once I have identified it).

This lists the UUIDs, but I can't get the names out of them:

gsettings get org.gnome.Terminal.ProfilesList list 
    ['b1dcc9dd-5262-4d8d-a863-c897e6d979b9', '0fef7ee8-d178-4fe1-a99f-c41c9c1f9597', '98bbb678-3533-484b-94c7-06bd88548766', '8bb3f482-c55b-4d70-9c47-f2cf4254d5bf']

Once I have the names, I can map them to guids and set the default one like so...

gsettings set org.gnome.Terminal.ProfilesList default 8bb3f482-c55b-4d70-9c47-f2cf4254d5bf

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.