From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sacha Chua Subject: Re: Sorting nodes by clocked time Date: Thu, 17 Apr 2014 20:09:37 -0400 Message-ID: <86k3an8pmm.fsf@sachachua.com> References: <87zjjk5p9q.fsf@bzg.ath.cx> <87ioq82pk9.fsf@bzg.ath.cx> <87a9bk2pbc.fsf@bzg.ath.cx> <87lhv442xy.fsf@bzg.ath.cx> <87mwfkb26u.fsf@bzg.ath.cx> <87eh0wb0qh.fsf@bzg.ath.cx> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48194) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WawNU-0005TX-KP for emacs-orgmode@gnu.org; Thu, 17 Apr 2014 20:10:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WawNL-000899-9y for emacs-orgmode@gnu.org; Thu, 17 Apr 2014 20:10:00 -0400 Received: from plane.gmane.org ([80.91.229.3]:53115) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WawNL-000891-2q for emacs-orgmode@gnu.org; Thu, 17 Apr 2014 20:09:51 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WawNJ-0001Os-MX for emacs-orgmode@gnu.org; Fri, 18 Apr 2014 02:09:49 +0200 Received: from 184.175.19.126 ([184.175.19.126]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 18 Apr 2014 02:09:49 +0200 Received: from sacha by 184.175.19.126 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 18 Apr 2014 02:09:49 +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 Noah Slater writes: Hello, Noah, all! > Using this a bit, it doesn't quite do what I want it to do. > Is there any way to sort recursively? > At the moment, calling org-sort-entries on the whole buffer only sorts the > top level nodes. Here's a rather inefficient hack (but hey, it seems to work =) ): (defun sacha/org-sort-recursively (type) (org-map-entries (lambda () (condition-case nil (org-sort-entries nil type) (error nil))))) Call with M-: (sacha/org-sort-recursively ?K) or merge the code into your own. Sacha