* [PATCH] Allow :urgency flags for org-notify
@ 2018-01-14 0:13 Jay Kamat
2018-01-15 15:26 ` Nicolas Goaziou
0 siblings, 1 reply; 2+ messages in thread
From: Jay Kamat @ 2018-01-14 0:13 UTC (permalink / raw)
To: Org Mode
[-- Attachment #1: Type: text/plain, Size: 624 bytes --]
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
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Respect-urgency-tags-for-org-notify-windows.patch --]
[-- Type: text/x-diff, Size: 1009 bytes --]
From dc8d8917720985e7006e75100ccc9f32c0e27b06 Mon Sep 17 00:00:00 2001
From: Jay Kamat <jaygkamat@gmail.com>
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
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Allow :urgency flags for org-notify
2018-01-14 0:13 [PATCH] Allow :urgency flags for org-notify Jay Kamat
@ 2018-01-15 15:26 ` Nicolas Goaziou
0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2018-01-15 15:26 UTC (permalink / raw)
To: Jay Kamat; +Cc: Org Mode, Peter Münster
Hello,
Jay Kamat <jaygkamat@gmail.com> writes:
> 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.
Thank you. I applied your patch on behalf of Org notify's author
(Cc'ed).
> 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?
Org notify is not in Org core, but in contrib/ directory, soon to be
moved to orgmode.org repository as a separate package.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-01-15 15:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-14 0:13 [PATCH] Allow :urgency flags for org-notify Jay Kamat
2018-01-15 15:26 ` Nicolas Goaziou
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.