From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: Scaling org-mode Date: Sun, 13 Sep 2009 12:52:58 -0400 Message-ID: <12636.1252860778@gamaville.dokosmarshall.org> References: <87my4zfleg.fsf@mahal.sjds.teklibre.org> Reply-To: nicholas.dokos@hp.com Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MmsLT-0004H1-Nn for emacs-orgmode@gnu.org; Sun, 13 Sep 2009 12:54:35 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MmsLP-0004Dm-4y for emacs-orgmode@gnu.org; Sun, 13 Sep 2009 12:54:35 -0400 Received: from [199.232.76.173] (port=42897 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MmsLO-0004De-TY for emacs-orgmode@gnu.org; Sun, 13 Sep 2009 12:54:30 -0400 Received: from vms173005pub.verizon.net ([206.46.173.5]:63262) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MmsLO-0000Ul-E6 for emacs-orgmode@gnu.org; Sun, 13 Sep 2009 12:54:30 -0400 Received: from gamaville.dokosmarshall.org ([98.110.172.159]) by vms173005.mailsrvcs.net (Sun Java(tm) System Messaging Server 6.3-7.04 (built Sep 26 2008; 32bit)) with ESMTPA id <0KPX004RN5JW9Q4E@vms173005.mailsrvcs.net> for emacs-orgmode@gnu.org; Sun, 13 Sep 2009 11:52:50 -0500 (CDT) In-reply-to: Message from d@teklibre.org (Dave =?us-ascii?Q?=3D=3Futf-8=3F?= =?us-ascii?Q?Q=3FT=3DC3=3DA4ht=3F=3D?=) of "Sat\, 12 Sep 2009 23\:45\:11 MDT." <87my4zfleg.fsf@mahal.sjds.teklibre.org> 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: Dave =?us-ascii?Q?=3D=3Futf-8=3FQ=3FT=3DC3=3DA4ht=3F?= =?us-ascii?Q?=3D?= Cc: emacs-orgmode@gnu.org Dave T=C3=A4ht wrote: > ... > so thought 2) would be to have it only attempt to construct background > agendas when the system is otherwise idle for a few minutes. I don't > know how to do that, I figure wrapping this bit with something that > could detect idleness instead of just running arbitrarily would be good. >=20 > (run-at-time nil 3600 'org-agenda-to-appt) >=20 > don't know how to detect idleness. >=20 [Apologies if this is off-topic - I haven't read your message carefully, as I was catching up on email between jobs.] Not sure whether it'll work any better, but there is run-with-idle-timer. C-h f run-with-idle-timer says: ,---- | run-with-idle-timer is an interactive compiled Lisp function in | `timer.el'. |=20 | (run-with-idle-timer SECS REPEAT FUNCTION &rest ARGS) |=20 | Perform an action the next time Emacs is idle for SECS seconds. | The action is to call FUNCTION with arguments ARGS. | SECS may be an integer, a floating point number, or the internal | time format (HIGH LOW USECS) returned by, e.g., `current-idle-time'. | If Emacs is currently idle, and has been idle for N seconds (N < SECS), | then it will call FUNCTION in SECS - N seconds from now. |=20 | If REPEAT is non-nil, do the action each time Emacs has been idle for | exactly SECS seconds (that is, only once for each time Emacs becomes idle= ). |=20 | This function returns a timer object which you can use in `cancel-timer'. `---- HTH, Nick