forked from mirrors/org-mode
Merge branch 'maint'
This commit is contained in:
commit
ea302ea5b5
|
@ -9188,9 +9188,8 @@ calls. You could auto-exclude these tags based on the availability of
|
||||||
the Internet, and outside of business hours, with something like this:
|
the Internet, and outside of business hours, with something like this:
|
||||||
|
|
||||||
#+begin_src emacs-lisp
|
#+begin_src emacs-lisp
|
||||||
(defun org-my-auto-exclude-fn (tag)
|
(defun my-auto-exclude-fn (tag)
|
||||||
(if (cond
|
(when (cond ((string= tag "net")
|
||||||
((string= tag "net")
|
|
||||||
(/= 0 (call-process "/sbin/ping" nil nil nil
|
(/= 0 (call-process "/sbin/ping" nil nil nil
|
||||||
"-c1" "-q" "-t1" "mail.gnu.org")))
|
"-c1" "-q" "-t1" "mail.gnu.org")))
|
||||||
((member tag '("errand" "call"))
|
((member tag '("errand" "call"))
|
||||||
|
@ -9198,7 +9197,7 @@ the Internet, and outside of business hours, with something like this:
|
||||||
(or (< hr 8) (> hr 21)))))
|
(or (< hr 8) (> hr 21)))))
|
||||||
(concat "-" tag)))
|
(concat "-" tag)))
|
||||||
|
|
||||||
(setq org-agenda-auto-exclude-function 'org-my-auto-exclude-fn)
|
(setq org-agenda-auto-exclude-function #'my-auto-exclude-fn)
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
You can apply this self-adapting filter by using a triple prefix
|
You can apply this self-adapting filter by using a triple prefix
|
||||||
|
|
Loading…
Reference in New Issue