Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I open my Documents folder more often than my Home folder. In Unity, if I want to open Documents, I click on the File manager icon in the launcher (this opens Home), then I click on Documents in the Nautilus bookmarks. I would prefer to just left-click once on that icon and have Documents open directly.

I am not able to drag folders into the launcher (is this a bug?) to create shortcuts there. (or is there another way to do it?)

I am not interested in right-clicking the icon (I know it is possible to add bookmarks in the right-click menu, but I just want to single-click that icon).

So what can I do?

share|improve this question
add comment

6 Answers

up vote 5 down vote accepted

Have a look at the answer to How to add my favorite places as a quicklist in my home's icon in Unity?

You can change the first Exec line to read Exec=nautilus Documents and it will open your Documents folder.

share|improve this answer
1  
I can't get this to work. I copied "/usr/share/applications/nautilus-home.desktop" to "~/.local/share/applications", then replaced "Exec=nautilus --no-desktop" with "Exec=nautilus Documents". Then restarted, but the icon still opens home. –  geoffrey May 16 '11 at 14:15
    
I tried it in a nearly pristine Natty VM and found that the folder ~/.local/share/applications is not there by default. Did you already have that folder (or did you create it)? Or did you copy /usr/share/applications/nautilus-home.desktop to a file with the name ~/.local/share/applications? –  elmicha May 16 '11 at 17:29
1  
I got it to work by copying and editing 'nautilus.desktop' and not 'nautilus-home.desktop' –  geoffrey May 17 '11 at 13:19
add comment

You can remove this home icon by dragging it to the bin at the bottom. You can then right click on the desktop and click 'Create Launcher...'.

Set the Type to 'Application' using the dropdown menu. Set the name to 'Documents' and the command to xdg-open /home/YOURNAME/Documents.

enter image description here

You can click the icon in the top left hand corner to change it to the home icon or any other icon if you wish. The home icon should be in the places/SIZE/folder-home.svg or places/SIZE/folder-home.png in the icon theme.

enter image description here

Click OK to create the launcher on the desktop.

enter image description here

You should then be able to drag and drop this to the launcher.

share|improve this answer
    
This would be interesting if it worked ... But I cannot drag and drop the icon to the launcher: the animation in the launcher seems to indicate that it is accepting the icon, but when I 'drop', the icon disappears. I also tried creating a desktop launcher for an 'application', and this one can be dropped on the launcher. But a 'location' launcher does not work. Is this a bug or a feature?? –  geoffrey May 15 '11 at 11:43
    
Probably a bug. I've changed my answer to something that should work by using an application launcher. Instead of being a direct link to the location it launches a program that opens the location in your default file browser. –  dv3500ea May 15 '11 at 13:05
    
thanks, that worked. by the way, no need to change the icon, it will be set automatically to the 'home-folder' icon when dropped on the launcher. It's a good solution, though one drawback is that when my Documents folder opens, another instance of the icon appears on the launcher. I'm voting up this answer, but will take a bit more time before accepting an answer. –  geoffrey May 16 '11 at 14:22
add comment

The accepted answer was basically still the correct answer for 12.04/12.10 & 13.04 (though some things about quicklists have changed in 12.10 & upcoming 13.04 but Not important here.

To set locally per user: Below is one single command in a terminal, copy & paste all, then press enter

cd 
mkdir -p .local/share/applications && \
cp /usr/share/applications/nautilus-home.desktop .local/share/applications/ && \
gedit .local/share/applications/nautilus-home.desktop

Edit the Exec=nautilus %U to Exec=nautilus Documents %U

In the launcher quicklists Home will now also open Documents, `Open a New Window will open your Home folder.

If you wish the launcher icon to say Documents instead of Home Folder then edit the Name=Home Folder line to Name=Documents, - (though I use something else here that makes more sense for both the launcher & unity panel - File Manager

If wanting Open a New Window to also open Documents then in the [Desktop Action Window] section edit it to Exec=nautilus Documents

Save & log out/in

If at any time wanting to re-edit the desktop then just run in a terminal -

gedit ~/.local/share/applications/nautilus-home.desktop

If for some reason wanting to do this globally then make the same edits to /usr/share/applications/nautilus-home.desktop with a root text editor

share|improve this answer
    
Tested and working, thanks very much. When I drag a file to the icon now (say I want to drop a file in the folder) it opens two Nautilus windows, the source & destination. Strange, but works well enough. –  Tom Brossman Dec 23 '12 at 10:54
    
Tom - I think that's from the %U in the Exec= line. So maybe re-open ~/.local/share/applications/nautilus-home.desktop & remove %U. See if it is the issue & if it fixes are there any ill effects from not having?. If all is good then edit the above answer & remove the %U from the Edit line. ( have just added a bit about changing the name of the launcher icon to Documents from Home Folder –  doug Dec 23 '12 at 16:36
add comment

Save this as documents.desktop open nautilus (the file manager) navigate to /usr/share/applications Look for the file named "Documents Folder" and drag and drop onto your side panel... works like you'd want (sorry about the weird spacing below..... )

[Desktop Entry]

Name=Documents Folder

Comment=Open your personal folder

Exec=nautilus Documents %U

Icon=folder

Terminal=false

StartupNotify=true

Type=Application

OnlyShowIn=GNOME;Unity;

Categories=GNOME;GTK;Core;

X-GNOME-Bugzilla-Bugzilla=GNOME

X-GNOME-Bugzilla-Product=nautilus

X-GNOME-Bugzilla-Component=general

X-GNOME-Bugzilla-Version=3.0.0

X-Ubuntu-Gettext-Domain=nautilus

Actions=Window;

[Desktop Action Window]

Name=Open a New Window

Exec=nautilus

OnlyShowIn=Unity;

share|improve this answer
add comment

Two ways I know:

Method 1:

Step 1:

gksudo gedit /usr/share/applications/nautilus.desktop

Step 2:

Change the Name= line to:

Name=Documents

Change the Exec= line to:

Exec=nautilus Documents

Step 3

Save the file as:

/usr/share/applications/nautilus-documents.desktop

A Document shortcut will appear and can be dragged and dropped where you want it to be. The other you are replacing may be removed/deleted as well.

Method 2

Step 1:

Enter this command:

gksudo gnome-desktop-item-edit --create-new /usr/share/applications/Documents.desktop

Step 2:

Change the values of the Type, Name, Command, and Comment fields so the lines say:

Type:Application
Name:Documents
Command:gnome-terminal Documents
Comment:Documents Folder

Step 3: Choose Icon

In the Command field, if it's clear, and you correctly type nautilus, it will complete your icon. If you want to choose another icon, such as your Documents icon, click the icon and you will be directed to an icon collection where you can choose the appropriate icon.

share|improve this answer
add comment

I think this List of custom Launchers & Quicklists for Unity

is what you're looking for.

share|improve this answer
    
He actually said that's not what he's looking for. –  htorque May 15 '11 at 10:03
    
No! He have to change the .desktop file and in this thread the posts explain how to do that! So why a negative mark? –  Wolf F. May 16 '11 at 4:22
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.