[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] [PATCH] Allow :urgency flags for org-notify
From: |
Jay Kamat |
Subject: |
[O] [PATCH] Allow :urgency flags for org-notify |
Date: |
Sat, 13 Jan 2018 19:13:40 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.0.91 (gnu/linux) |
Hi,
I recently began using the org-notify package, and I would like to pass
the :urgency flag to `notifications-notify' occasionally. This small
patch passes the :urgency key from the org-notify configuration on to
`notitifications-notify'.
For example, after this patch, you can:
(org-notify-add 'test-notifications
'(:time "10m" :period "1m" :actions -notify/window :urgency critical))
And get notifications labeled as critical in that way.
Eventually, I would like to write an alert
(https://github.com/jwiegley/alert) backend for org-notify, would that
be suitable for inclusion in the core package?
Thanks,
-Jay
>From dc8d8917720985e7006e75100ccc9f32c0e27b06 Mon Sep 17 00:00:00 2001
From: Jay Kamat <address@hidden>
Date: Sat, 13 Jan 2018 19:03:07 -0500
Subject: [PATCH] Respect :urgency tags for org-notify windows
* contrib/lisp/org-notify.el (org-notify-action-notify): pass :urgency
to notifications-notify.
---
contrib/lisp/org-notify.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/contrib/lisp/org-notify.el b/contrib/lisp/org-notify.el
index 5f64d3162b..96e7d4ee27 100644
--- a/contrib/lisp/org-notify.el
+++ b/contrib/lisp/org-notify.el
@@ -373,6 +373,7 @@ org-notify window. Mostly copied from
`appt-select-lowest-window'."
:title (plist-get plist :heading)
:body (org-notify-body-text plist)
:timeout (if duration (* duration 1000))
+ :urgency (plist-get plist :urgency)
:actions org-notify-actions
:on-action 'org-notify-on-action-notify)))
(setq org-notify-on-action-map
--
2.11.0
- [O] [PATCH] Allow :urgency flags for org-notify,
Jay Kamat <=