[Org] Don’t activate timers repeatedly
This approach may need to be generalized to other timers as well. Don’t know (yet) whether there is some predefined way in ELisp to do this.
This commit is contained in:
parent
51b72d7f5c
commit
0d67273805
8
init.el
8
init.el
|
@ -592,8 +592,12 @@ _h_ _l_ _o_k _y_ank
|
|||
;; opening them manually
|
||||
(mapc #'find-file-noselect org-agenda-files)
|
||||
|
||||
(run-with-timer 0 3600 #'org-clock-save)
|
||||
(run-with-idle-timer 20 t #'db/export-diary)))
|
||||
(unless (memq #'org-clock-save
|
||||
(mapcar #'timer--function timer-list))
|
||||
(run-with-timer 0 3600 #'org-clock-save))
|
||||
(unless (memq #'db/export-diary
|
||||
(mapcar #'timer--function timer-idle-list))
|
||||
(run-with-idle-timer 20 t #'db/export-diary))))
|
||||
|
||||
(use-package db-utils
|
||||
:commands (endless/fill-or-unfill
|
||||
|
|
Loading…
Reference in New Issue