On Windows it is possible to create a link holding the Meta (Alt) key while dragging a file.

Is it possible to create a link to a file when it is dragged from an Explorer over to emacs holding the Meta key?

I know Onenote suports this behaviour, although you can choose to insert the whole file or just link to it.

Using dired (Ctrl-x d) to navigate to the file and copy it's name with w is a bit cumbersome. One has to add the path to the file manually. May there be also a better way to do this?

  • 2
    The usal way is to do org-store-link (the recommended binding in the Org mode manual is C-c l) on the file (or its directory entry) and then org-insert-link (recommended binding: C-c C-l) in your org file. I imagine it would be possible to associate these actions with a D-D operation, but I don't know how to do that.
    – NickD
    May 18, 2020 at 14:57
  • Nice! I did not expect org-store-link to work in dired. I wil use this till I find how to drag and drop. Also I found the org-attach function useful although more sofisticated. May 19, 2020 at 8:59


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.