From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thorsten Jolitz Subject: Re: How to find the headline matching a string Date: Sat, 31 May 2014 22:14:49 +0200 Message-ID: <87ha45r9hi.fsf@gmail.com> References: <87bnuedl38.fsf@ericabrahamsen.net> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50011) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WqpgL-0002XZ-RV for emacs-orgmode@gnu.org; Sat, 31 May 2014 16:15:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WqpgF-0000gV-Mc for emacs-orgmode@gnu.org; Sat, 31 May 2014 16:15:09 -0400 Received: from plane.gmane.org ([80.91.229.3]:53697) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WqpgF-0000fo-H3 for emacs-orgmode@gnu.org; Sat, 31 May 2014 16:15:03 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WqpgD-0007QL-Tq for emacs-orgmode@gnu.org; Sat, 31 May 2014 22:15:01 +0200 Received: from g231233123.adsl.alicedsl.de ([92.231.233.123]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 31 May 2014 22:15:01 +0200 Received: from tjolitz by g231233123.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 31 May 2014 22:15:01 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Chris Poole writes: > Eric Abrahamsen: >> the `org-map-entries' function can be given a scope of 'agenda > > That worked perfectly, thanks. Here's what I ended up with: > > (org-map-entries (lambda () > (when (equal title (org-get-heading t t)) > (org-entry-put (point) "TODO" "DONE"))) > tag 'agenda) As much as I like the powerful `org-map-entries', I wonder if it will coexist with `org-element-map' in the future, since it does not use the new parser. Whats the recommendation here? Should one rather use ,----------------------------------------------------------- | (org-element-map (org-element-parse-buffer) 'headline (lambda () ...)) `----------------------------------------------------------- nowadays, or do both functions serve different purposes, or is it just a matter of taste? -- cheers, Thorsten