emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Orgmode] Scaling org-mode


From: Dave Täht
Subject: [Orgmode] Scaling org-mode
Date: Sat, 12 Sep 2009 23:45:11 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.91 (gnu/linux)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


I have really been enjoying importing my life into org-mode, which I've
been doing for about two months now. 

But.

It currently visits about 100 files and 10k of text to construct the
agenda. It's starting to get kind of slow and interrupt my workflow,
particularly the background process that scans them. 

While the system is effectively frozen, my message buffer fills up with
messages about setting the flyspell dictionary to en, etc. This is quite
annoying with text to speech turned on. I ended up just having appts
spoken.

;; quick hack for saying announcements, need more thought turned into it.

(when window-system
  (defun dtaht/say-stuff (id msg &optional delay vattrib hattrib font) 
    "Speak a message msg. Currently requires say.el"
    (unless vattrib (setq vattrib "top"))
    (unless hattrib (setq hattrib "right"))
    (unless delay (setq delay 5000))
    (unless font (setq font "Arial 12"))
    (save-window-excursion
      (say (dtaht/ssml-escape msg)
        ))))

;; my personal fav, run every 15 minutes

(defun nag-timer () "Nag me when there isn't a clock running"  
  (interactive)
  (unless (marker-buffer org-clock-marker)
    (say "Are you mating now?")))

It gets a bit chunky even when all the org files are in memory (and I
have gobs of memory).

Solution #1) cut the number of files down - is a good one. I probably
can cut those files easily in half right now. The problem is that I have
about 600 more files to import (scenes from a book), and I really like
the idea of being able to know what my characters are doing in 2023, and
separate files was kind of useful at one point.

That's a couple hundred k of text (what I have in there now is mostly
"normal" items for managing my personal and professional life)

Solution #2) Make org-mode faster. I am compiling and installing
org-mode from git at the moment. So it's compiled. I have a lot of hooks
installed for text buffers - At minimum, auto-capitalize, flyspell, yas,
wrap, and abbrev. Most (all?) of those are compiled, too, but aren't
needed to be run or initialized when merely being visited.

so thought 1) would be to come up with some sort of text mode hook that
only hooks in when a human is viewing or editing the buffer, not when it
is happening programmatically.

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.

  (run-at-time nil 3600 'org-agenda-to-appt)

don't know how to detect idleness.

And thought 0) would be to understand emacs well enough to profile
what's really going on as maybe "starting a new flyspell process" is not
really the problem but a symptom, but I don't (yet). (suggestions
desired. I have read up a bit on emacs profiling)

I am deeply grateful for the existence of org-mode and the fine work
going into it. I wrote a nice blog entry about it recently. 

http://the-edge.blogspot.com/2009/08/going-retro-re-adopting-emacs.html

TIA.

- -- 
Dave Taht
http://the-edge.blogspot.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.8+ <http://mailcrypt.sourceforge.net/>

iEYEARECAAYFAkqshuUACgkQpdejJcOV4uRkTwCgyz5IMWJTzCHa8CmUAgU/fyIa
cvwAoJKQ5Gr+1vlSAbEfbKob76xJIvB8
=/Xdv
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]