From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Barton Subject: Re: alter all subtrees containing specific tag Date: Sun, 08 Mar 2009 13:42:52 +0000 Message-ID: <49B3CB5C.6020108@manor-farm.org> References: <877i303a9w.fsf@it.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LgJHc-0005xW-BK for emacs-orgmode@gnu.org; Sun, 08 Mar 2009 09:43:12 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LgJHa-0005vg-CU for emacs-orgmode@gnu.org; Sun, 08 Mar 2009 09:43:11 -0400 Received: from [199.232.76.173] (port=53281 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LgJHa-0005vW-6N for emacs-orgmode@gnu.org; Sun, 08 Mar 2009 09:43:10 -0400 Received: from a2s22.a2hosting.com ([69.39.86.130]:49531) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LgJHZ-0005yC-JM for emacs-orgmode@gnu.org; Sun, 08 Mar 2009 09:43:09 -0400 Received: from [217.146.125.41] (helo=firewall.banter.local) by a2s22.a2hosting.com with esmtp (Exim 4.69) (envelope-from ) id 1LgJHY-0005on-5W for emacs-orgmode@gnu.org; Sun, 08 Mar 2009 09:43:08 -0400 Received: from localhost (localhost [127.0.0.1]) by firewall.banter.local (Postfix) with ESMTP id 8E50ECC81 for ; Sun, 8 Mar 2009 13:43:05 +0000 (GMT) Received: from firewall.banter.local ([127.0.0.1]) by localhost (firewall.banter.local [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jpdZKKwGCyOW for ; Sun, 8 Mar 2009 13:42:53 +0000 (GMT) Received: from [192.168.0.55] (scamper.banter.local [192.168.0.55]) by firewall.banter.local (Postfix) with ESMTP id 10763CC80 for ; Sun, 8 Mar 2009 13:42:53 +0000 (GMT) In-Reply-To: <877i303a9w.fsf@it.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: emacs-orgmode@gnu.org > I use pgg to encrypt some org subtrees (e.g. the ones containing > passwords). At the moment I have to encrypt/decrypt them one at a > time by selecting the appropriate region and running > pgg-encrypt-region/pgg-decrypt-region. > I want to make a function that will automatically encrypt/decrypt all > subtrees (in the current buffer) whose headings contain an :ENCRYPT: tag. > I tried using org-map-entries, but it seems to restore the buffer to > its original state after returning. > Is there a quick way to get the start and end points of a subtree, or > place region around it? and a quick way to jump to the next heading > with a given tag? > Not really an answer, but I use epa and encrypt the whole file, which I find much fiddly. You can get epa to play nicely with org mode by putting something like: -*- mode:org; epa-file-encrypt-to: ("me@mmyemail.com") -*- at the top of your encrypted file. Ian.