From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sebastian Subject: Re: Re: add a whole directory as one item to refile targets Date: Sat, 17 Oct 2009 14:59:22 +0200 Message-ID: <1255784362.11967.16.camel@beteigeuze> References: <938fae2d0910041530v51cdaac4jb8db88b6cb1a8b56@mail.gmail.com> <938fae2d0910101448j2c39d67aw4950c7899c3307a1@mail.gmail.com> <87ocoeq4xw.fsf@gollum.intra.norang.ca> <938fae2d0910120648t5147b4d9y3339d3f06bc732e7@mail.gmail.com> <1255366066.5500.12.camel@beteigeuze> <938fae2d0910170358m67c6f078w2cc481a9ed0035a2@mail.gmail.com> Reply-To: sebastian_rose@gmx.de Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mz8si-0000u1-4x for emacs-orgmode@gnu.org; Sat, 17 Oct 2009 08:59:36 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mz8sa-0000nV-Ik for emacs-orgmode@gnu.org; Sat, 17 Oct 2009 08:59:33 -0400 Received: from [199.232.76.173] (port=48308 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mz8sZ-0000mm-Sx for emacs-orgmode@gnu.org; Sat, 17 Oct 2009 08:59:27 -0400 Received: from mail.gmx.net ([213.165.64.20]:38668) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1Mz8sY-0002yo-PY for emacs-orgmode@gnu.org; Sat, 17 Oct 2009 08:59:27 -0400 In-Reply-To: <938fae2d0910170358m67c6f078w2cc481a9ed0035a2@mail.gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Eraldo Helal Cc: Bernt Hansen , Org-Mode , Carsten Dominik Am Samstag, den 17.10.2009, 12:58 +0200 schrieb Eraldo Helal: > Thank you very much for sharing this! > That seems to be more than what I need. > > A waaay easier solution would be to be able to refile/save a headline > to a non-predefined target. > > just like it is the case with "find file" (C-x C-f) > in other words: being able to "find a file" to use as refile target > (if it does not exist > create) > > Wouldn't that be an awesome option? Yes. This does so. Note: there's no testing for the '*.org' extension and writability... (defun sr-add-file-to-org-refile-targets ( file ) "Add a single file to org-refile targets. Eventually create it." (interactive "FNew refile target: ") (when (not (file-exists-p file)) (access-file file)) (setq sr-org-refile-targets (append (list file) sr-org-refile-targets)) (message "org-refile-targets: \n%s" sr-org-refile-targets)) HTH Sebastian