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.

Possible Duplicate:
How to drag a folder to the launcher from Nautilus

Why isn't it allowed automatically? How can I do it? Thanks. If it's not possible, how can I access folder in the fastest way? How do you do it?

share|improve this question

marked as duplicate by WarriorIng64, Jorge Castro, 8128, jokerdino, fossfreedom Apr 27 '12 at 9:40

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

    
This link has an answer and a quick example. Good luck! askubuntu.com/questions/80013/… –  darkdragn Apr 27 '12 at 4:33
    
Well, this is for 12.04 –  mrSuperEvening Apr 27 '12 at 4:38
3  
@darkdragn That's for a program. This is specifically about pinning arbitrary files/folders, which is different. –  WarriorIng64 Apr 27 '12 at 5:08
    
@WarriorIng64 Couldn't the user just put Exec= nautilus /media/dumpLocal in the .desktop file to open the desired folder. If they want a file, just come up with the program that launches it, and put it with a ref to the file in the exec line. –  darkdragn Apr 27 '12 at 9:12
add comment

2 Answers 2

You can use the way described by darkdragn. This way you can add your own quick menues. You find a complete guide to that method here: http://maketecheasier.com/8-really-useful-ubuntu-unity-quicklists/2011/05/07 (and on a lot of other pages)

share|improve this answer
add comment

What you can do is to create a bash shell script executes the application you want with the file as the argument to be opened. Save that script in /usr/local/bin and permit execution. Then create a launcher that executes your script. Here's an example where I decrypt a file display it with leafpad and when leafpad is terminated, delete the created file.

#!/bin/bash
#Decrypt notecase
gpg -o ~/Bin/.notecase -d ~/WIP/notecase.txt.gpg
leafpad ~/Bin/.notecase
rm ~/Bin/.notecase

The following is the launcher file I created by editing a copy of system notecase.desktop file. Items I changed start and end with ** which you'd remove before saving as notecase.desktop. I stored it in ~/.local/share/applications/notecase.desktop and then dragged that file icon to the launcher bar.

[Desktop Entry]
Categories=Application;Office;Utility;
Comment=**Notes Manager**
Encoding=UTF-8
Exec=**notecase**
GenericName=Hierarchical Note Manager
Icon=**/usr/share/icons/Faenza/apps/scalable/gnome-sticky-notes-applet.svg**
MimeType=application/notecase-plain;application/notecase-enc;
Name=**NoteCase notes manager**
Name[en_US]=NoteCase
Terminal=false
TryExec=notecase
Type=Application
X-HildonDesk-ShowInToolbar=true
X-Osso-Service=com.nokia.notecase
X-Osso-Type=application/x-executable
X-Window-Icon=notecase
X-Window-Icon-Dimmed=notecase
share|improve this answer
add comment

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