How can I change the Desktop background or the screensaver in Terminal only?

0

I have a few images in a directory and I can only use the Terminal

Wasi

Posted 2012-09-28T19:31:58.513

Reputation: 125

Answers

0

Try this:

gconftool-2 -t str -s /desktop/gnome/background /where/is/your/image/linux_12.jpg

poz2k4444

Posted 2012-09-28T19:31:58.513

Reputation: 794

For screensaver, I used $gconftool-2 --direct --config-schema xml:readwrite:/etc/gnconf.xml.mandatory --type boolean --set /apps/gnome-screensaver/lock_enabled true

I get the following error: Error setting value: Can't overwrite existing read-only value: Value for '/apps/gnome-screensaver/lock_enabled' set in a read-only source at the fron of your configuration path

Any idea on how to solve this? chmod didn't work – Wasi – 2012-10-02T14:16:41.133

@Wasi did you try with sudo? (I have to ask) – poz2k4444 – 2012-10-02T14:28:48.660

I did. Same error – Wasi – 2012-10-02T17:09:04.797

@Wasi what permission does it have?? I mean more accurately, does it have sticky bit? – poz2k4444 – 2012-10-02T23:48:34.553

1

I am not sure what version of GNOME you are using. Assuming you are using one of the later versions of GNOME, you can try this command to change the background:

gsettings set org.gnome.desktop.background picture-uri file:///path/to/your/image.png

Change the path to the file and the wallpaper will be changed accordingly.

GNOME started migrating most of its settings from gconf to dconf and as such, the other answer will not work for newer versions of GNOME.

(Source)

jokerdino

Posted 2012-09-28T19:31:58.513

Reputation: 2 330