Use Any Folder For Your Ubuntu Desktop (Even a Dropbox Folder)

By Trevor Bekolay on May 20th, 2010

By default, Ubuntu creates a folder called Desktop in your home directory that gets displayed on your desktop. What if you want to use something else, like your Dropbox folder? Here we look at how to use any folder for your desktop.

Not only can you change your desktop folder, you can change the location of any other folder Ubuntu creates for you in your home folder, like Documents or Music – and this works in any Linux distribution using the Gnome desktop manager.

sshot-1

In this example, we’re going to change desktop to show our Dropbox folder. Open your home folder in a File Browser by clicking on Places > Home Folder.

screenshot_002

In the Home Folder, open the .config folder. By default, .config is hidden, so you may have to show hidden folders (temporarily) by clicking on View > Show Hidden Files.

sshot-2

Then open the .config folder by double-clicking on it.

screenshot_006

Now open the user-dirs.dirs file…

screenshot_007

If double-clicking on it does not open it in a text editor, right-click on it and choose Open with Other Application… and find a text editor like Gedit.

Change the entry associated with XDG_DESKTOP_DIR to the folder you want to be shown as your desktop. In our case, this is $HOME/Dropbox.

Note: The “~” shortcut for the home directory won’t work in this file (use $HOME for that), but an absolute path (i.e. a path starting with “/”) will work.

screenshot_009

Feel free to change the locations of the other folders as well.

Save and close user-dirs.dirs. At this point you can either log off and then log back on to get your desktop back, or open a terminal window Applications > Accessories > Terminal and enter:

killall nautilus

Nautilus (the file manager in Gnome) will restart itself and display your newly chosen folder as the desktop!

screenshot_010

This is a cool trick to use any folder for your Ubuntu desktop. What did you use as your desktop folder? Let us know in the comments!

Trevor is our resident Linux geek, but always keeps his eyes open for neat Windows tricks too.

  • Published 05/20/10
More Articles You Might Like

Enter Your Email Here to Get Access for Free:

Go check your email!