From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jesse Johnson Subject: sort habits by priority Date: Thu, 27 Apr 2017 15:33:05 -0700 Message-ID: <86583c1c-ed6a-6229-0e46-f48052edfa15@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60780) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d3ryL-0004sz-M1 for emacs-orgmode@gnu.org; Thu, 27 Apr 2017 18:33:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d3ryH-0000pM-OW for emacs-orgmode@gnu.org; Thu, 27 Apr 2017 18:33:13 -0400 Received: from mail-pf0-x22c.google.com ([2607:f8b0:400e:c00::22c]:35547) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1d3ryH-0000p4-HI for emacs-orgmode@gnu.org; Thu, 27 Apr 2017 18:33:09 -0400 Received: by mail-pf0-x22c.google.com with SMTP id v14so39476822pfd.2 for ; Thu, 27 Apr 2017 15:33:09 -0700 (PDT) Received: from [192.168.1.199] (c-67-182-149-27.hsd1.wa.comcast.net. [67.182.149.27]) by smtp.gmail.com with ESMTPSA id e13sm6278394pfb.30.2017.04.27.15.33.06 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 27 Apr 2017 15:33:06 -0700 (PDT) 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" To: emacs-orgmode@gnu.org I want to sort habits by priority, such that priority overrides all other criteria (schedule, deadline, consistency, etc.). In attempting to implement this I discovered that org-habit-get-priority is an inline function and thus cannot be overridden by the user. There seems to be no straightforward way to accomplish my goal without editing the org source code directly. I am not the only one to run into this problem: http://stackoverflow.com/questions/37200762/sort-todays-habits-by-priority-in-main-agenda-view I think the best solution is either to make org-habit-get-priority a regular function (assuming this doesn't cause a serious performance degradation) or to add user-customizable variable(s) which can configure how habits are prioritized. Thoughts? Jesse