By Aaron Hampshire

Enable Desktop Icons in elementary Luna


[Translation and additions by Luca Tavecchio from this original article]

Initial Discussion
This workaround utilizes Nautilus to use the desktop in a way we are familiar with in other linux distros.

It may use extra memory. However, here is Nautilus running on my Pentium IV with 3 Gb of ram. It doesn't run well on older hardware, but I will let you judge if it is too much for your system.
This work around is not perfect and may not be fit your system for four reasons:
  1. Even if its works now, it may break for many reasons with a new update in the future.

  2. It only permits the creation of one desktop. So no different icons on different workspaces.

  3. Folders created on the desktop are managed by Nautilus, not Files. There may be a way around this, but I haven't figured one out, yet.

  4. Nautilus also seems to override the default file manager of the Dropbox indicator.

Still interested? Let's proceed!

Initial Instructions
  1. As already mentioned, we will need Nautilus:
    sudo apt-get install –no-install-recommends nautilus dconf-tools
    NOTE: --no-install-recommends avoid the installation of the entire gnome desktop but will not prevent Brasero from also installing.

  2. From Slingshot open dconf-editor and in orggnomenautiluspreferences desktop-is-home-dir, double-click. The first click will enable it and the second will disable it.

  3. Now we need to edit the file ~/.config/user-dirs.dirs which is located in a hidden folder in our Home. (Press CTRL + H to show hidden folder.)

    At the bottom of this file, add the line XDG_DESKTOP_DIR="$HOME/Desktop" and delete this line if present: XDG_DESKTOP_DIR:..

    NOTE: It may be necessary to change "Desktop" with your language translation. i.e., in my case it was "Scrivania".

  4. Now create your Desktop folder in Home and run in terminal: nautilus -n. (-n means only-desktop mode)

    Now try to right click the desktop. The context menu should work.

Fix "Change Desktop Background"
  1. Now we need to fix the “change desktop background” entry in the right click menu. As administrator open /usr/bin and search gnome-control-center and rename it as gnome-control-center.bak.

  2. Create an empty file, open it with Scratch, and fill it with these lines.
    function background
    {
    switchboard -o desktop.plug
    }
    "$1"
    exit 0
    Save it as gnome-control-center

  3. After closing Scratch, go to the new gnome-control-center and in the context menu under proprieties mark it as executable.

    Now if you right click on the background and select change desktop background, it will launch the desktop plug.

Autostart the Working Desktop
  1. In order to make this modification permanent at login, open dconf-editor and in orgpantheoncerbere add in the monitored-process line nautilus -n.

    If you have never modified that line it look like this at the end:
    ['wingpanel', 'plank', 'slingshot-launcher --silent', 'nautilus -n']

  2. Close dconf-editor and you're done! Now you have a working desktop.

Theme it up!
Because elementary-icons-theme doesn't come with a desktop folder icon, I've repacked the old icon made by Dan Rabbit.
  1. It's available on Devianart. All the credits go to Dan Rabbit, I simply download the repackaged the original.
  2. Unzip and copy it to ~/.icons/elementary

Final Remarks
The final result will look like this.
Of course you will also have all the icons/files that you want on your desktop.