From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike McLean Subject: BUG & [PATCH]: org-clone-subtree-with-time-shift doesn't clean empty property drawers in entire subtree Date: Sat, 04 Dec 2010 12:59:43 -0500 Message-ID: <4CFA818F.8070601@pobox.com> Reply-To: mike.mclean@pobox.com Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=33042 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1POwP3-0000eG-A4 for emacs-orgmode@gnu.org; Sat, 04 Dec 2010 13:00:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1POwP2-0006OE-0T for emacs-orgmode@gnu.org; Sat, 04 Dec 2010 13:00:09 -0500 Received: from b-pb-sasl-quonix.pobox.com ([208.72.237.35]:42311 helo=sasl.smtp.pobox.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1POwP1-0006H1-Tj for emacs-orgmode@gnu.org; Sat, 04 Dec 2010 13:00:07 -0500 Received: from sasl.smtp.pobox.com (unknown [127.0.0.1]) by b-sasl-quonix.pobox.com (Postfix) with ESMTP id 447EF8B61 for ; Sat, 4 Dec 2010 12:59:44 -0500 (EST) Received: from b-pb-sasl-quonix. (unknown [127.0.0.1]) by b-sasl-quonix.pobox.com (Postfix) with ESMTP id 3DAC08B60 for ; Sat, 4 Dec 2010 12:59:44 -0500 (EST) Received: from MACXMCLEANM.local (unknown [76.18.212.62]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by b-sasl-quonix.pobox.com (Postfix) with ESMTPSA id 093698B5F for ; Sat, 4 Dec 2010 12:59:43 -0500 (EST) 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 If using org-clone, C-c C-x c, on a subtree instead of a single item, the loop to call org-remove-empty-drawer-at isn't executing on every item of the subtree. Changing the re-search-forward seems to do the trick. Mike --- lisp/org.el | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 66514a2..e5a20d3 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -7603,7 +7603,7 @@ and still retain the repeater to cover future instances of the task." (and idprop (if org-clone-delete-id (org-entry-delete nil "ID") (org-id-get-create t))) - (while (re-search-forward org-property-drawer-re nil t) + (while (re-search-forward org-property-start-re nil t) (org-remove-empty-drawer-at "PROPERTIES" (point))) (goto-char (point-min)) (when doshift -- 1.7.3.2