emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Orgmode] Re: create links for all marked files in dired


From: Fabian Braennstroem
Subject: [Orgmode] Re: create links for all marked files in dired
Date: Wed, 28 Nov 2007 21:39:48 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.0

Hi to both,

thanks for your help ...

Bastien schrieb am 11/27/2007 02:47 PM:
> Hi Fabian,
> 
> Fabian Braennstroem <address@hidden> writes:
> 
>> is there a chance to create links from the marked files in a
>> dired buffer using org-mode internal functions?
> 
> I already suggested something for this here:
> 
>   http://article.gmane.org/gmane.emacs.orgmode/4440
> 
> If you want to create a list of links from dired and copy this list to
> the kill-ring, maybe you can use something like this as well:
> 
> (defun my-copy-dired-files-in-kill-ring ()
>   "Copy files names in the kill ring."
>   (interactive)
>   (let ((files (dired-map-over-marks (dired-get-filename) nil)))
>     (kill-new
>      (mapconcat 
>       (lambda (f) 
>       (concat "[[file:" f "][" 
>               (file-name-nondirectory f) "]]"))
>       files "\n"))
>     (message "%d Org links copied to the kill-ring" (length files))))
> 
> Does that help?

Works great! I was thinking about it , but just in python ;-)
Greetings!





reply via email to

[Prev in Thread] Current Thread [Next in Thread]