From: Florian Adamsky <fa-org-mode@haktar.org>
To: emacs-orgmode@gnu.org
Subject: Confusion about org-refile-targets-verify-function
Date: Wed, 03 Feb 2016 12:06:11 +0100 [thread overview]
Message-ID: <87a8ni59zw.fsf@haktar.org> (raw)
Hey,
I'm using Emacs 24.5.1 and Org-mode 8.3.3 (15d591e) and try to filter
the output of my refile targets. For me, every headline that contains a
subtree with the name "tasks" is a project. Therefore, I would to filter
my refile targets to those which contains the name "tasks".
I use emacs -q and have the following configuration:
--8<---------------cut here---------------start------------->8---
(setq org-agenda-files (list "~/test.org" ))
(setq org-refile-targets '((org-agenda-files :maxlevel . 10)))
(setq org-refile-use-outline-path t)
(setq org-refile-target-verify-function (lambda ()
(string= (nth 4 (org-heading-components)) "tasks")))
--8<---------------cut here---------------end--------------->8---
The org-mode file test.org contains the following content:
--8<---------------cut here---------------start------------->8---
#+title: Test Org Mode
#+STARTUP: hidestars
* Foo
** tasks
* Bar
** Test
*** Fnord
**** tasks
*** Bla
**** tasks
* Fnord
** Nothing
--8<---------------cut here---------------end--------------->8---
The output from org-refile is:
- tasks (test.org)
- tasks/tasks (test.org)
I had expected that the output will be:
- Foo/tasks
- Bar/Test/Fnord/tasks
- Bar/Test/Bla/tasks
What am I doing wrong? Thanks in advance!
Best regards
--
Florian Adamsky
http://florian.adamsky.it/
next reply other threads:[~2016-02-03 11:06 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-03 11:06 Florian Adamsky [this message]
-- strict thread matches above, loose matches on Subject: below --
2016-02-03 13:46 Confusion about org-refile-targets-verify-function Florian Adamsky
2016-02-25 13:43 ` Nicolas Goaziou
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87a8ni59zw.fsf@haktar.org \
--to=fa-org-mode@haktar.org \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.