emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Richard Lawrence <richard.lawrence@berkeley.edu>
To: emacs-orgmode@gnu.org
Subject: Call org-map-entries just on children?
Date: Mon, 07 Feb 2011 09:51:36 -0800	[thread overview]
Message-ID: <87ipwvd97b.fsf@berkeley.edu> (raw)

Hi all,

I'm sure I'm just being thick here, but any help would be appreciated...

I want to call org-map-entries in a way that calls a function at each
*child* of the current tree, but not at the current tree itself.  That
is, for some function f, if my Org file looks like this:

* Paper 1
** Student 1
** Student 2
...

I want to call f at "Student 1", "Student 2", etc. but not at "Paper 1".
But if point is positioned at "Paper 1", then

(org-map-entries 'f nil 'tree)

first calls f at the "Paper 1" entry, not the "Student 1" entry.  How
can I apply f just to the *children* of "Paper 1"?

(The reason I need to do this is that f needs to enforce that each of
the children has a value for a certain property, but the parent entry
should not have this property.)

Thanks!

Richard

             reply	other threads:[~2011-02-07 21:13 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-07 17:51 Richard Lawrence [this message]
2011-02-08 15:43 ` Call org-map-entries just on children? Bastien
2011-02-08 18:52   ` Richard Lawrence

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ipwvd97b.fsf@berkeley.edu \
    --to=richard.lawrence@berkeley.edu \
    --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 public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).