0

on ubuntu 20.04, this was working well to tweak my setting via cli:

dconf write /org/gnome/desktop/interface/text-scaling-factor 0.9

however on ubuntu 22.04, I can only read the value

$ dconf read /org/gnome/desktop/interface/text-scaling-factor    
0.94999999999999996

$ dconf write /org/gnome/desktop/interface/text-scaling-factor 0.9 error: The given address is empty

Any idea how to solve ? Gnome tweaks can modify it, but I want to do it via cli

n0tis
  • 197

1 Answers1

1

What is the result of echo $DBUS_SESSION_BUS_ADDRESS

If this environment variable is not set then try setting it with:

export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/$UID/bus

Then try your dconf write again.

codlord
  • 2,506
  • it works, variable was indeed empty, thank you !!! would it be wise to put this in my .bashrc ? – n0tis Jul 19 '23 at 10:14
  • @n0tis I guess that would work, but not sure why it is not already set, on all my PC's/terminals it's set by default. In your case is this just a normal GUI terminal session as a non-root user? Or are you logged in remotely via VNC or SSH or something like that? – codlord Jul 19 '23 at 10:24
  • This my my local machine (not connected via ssh/VNC). Very interrestingly, the variable is correctly set by default in virtual terminal, but not in my usual termnial (accessed via gnome + terminator). This bugs appeared after my update from 20.02 to 22.04 – n0tis Jul 19 '23 at 10:33
  • I'm on 22.04.2 LTS. I did see something in another post about certain dbus packages which should be installed, when I do apt list --installed |grep ^dbus it shows dbus, dbus-x11 and dbus-user-session. So maybe check you have same packages installed? But I really don't know what all this stuff means/does, I only answered as I has a similar issue as you when writing a backup script which runs as cron - in that case the environment variable was not set and I had to do it in the script. – codlord Jul 19 '23 at 10:42
  • thank you, I do have the same package installed, I'll dig a bit more and maybe open another post about this question – n0tis Jul 19 '23 at 10:44
  • solved, it was terminator config issue, because I did this trick a few weeks ago : https://askubuntu.com/questions/1189243/why-is-terminator-sending-double-characters-to-terminals-that-arent-selected-in thanks for your help – n0tis Jul 19 '23 at 10:52