summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemse2014-04-16 00:14:06 +0200
committerGravatar Tom Willemse2014-04-16 00:20:36 +0200
commit0bb6a0380066e5e18fa56c1c4caef4eee2499f17 (patch)
tree7372ca9db17ef2a14857be26d9f46cc85eacd3fa
parent2a5d0c68f5cddeb9feab763a34121079c90e738c (diff)
downloademacs-0bb6a0380066e5e18fa56c1c4caef4eee2499f17.tar.gz
emacs-0bb6a0380066e5e18fa56c1c4caef4eee2499f17.zip
Use stumpwm for jabber notifications
-rw-r--r--.emacs.d/site-lisp/jabber-init.el10
1 files changed, 10 insertions, 0 deletions
diff --git a/.emacs.d/site-lisp/jabber-init.el b/.emacs.d/site-lisp/jabber-init.el
index 35831e5..ab760aa 100644
--- a/.emacs.d/site-lisp/jabber-init.el
+++ b/.emacs.d/site-lisp/jabber-init.el
@@ -26,6 +26,14 @@ Insert PROPOSED-ALERT in the buffer if it is non-nil."
(ewoc-enter-last jabber-chat-ewoc (list :notice proposed-alert
:time (current-time)))))))
+(defun jabber-init-stumpwm-echo (from buffer text title)
+ "Use stumpwm to echo a message has arrived."
+ (oni:stumpwm-echo title))
+
+(defun jabber-init-stumpwm-echo-muc (nick group buffer text title)
+ "Use stumpwm to echo a message has arrived."
+ (oni:stumpwm-echo title))
+
(setq jabber-account-list
(mapcar (lambda (str) (list (concat str "/" system-name)))
'("tom@ryuslash.org" "ryuslash@ninthfloor.org"))
@@ -63,6 +71,8 @@ Insert PROPOSED-ALERT in the buffer if it is non-nil."
;; (add-hook 'jabber-alert-message-hooks #'jabber-message-libnotify)
;; (add-hook 'jabber-alert-muc-hooks #'jabber-muc-libnotify)
+(add-hook 'jabber-alert-message-hooks #'jabber-init-stumpwm-echo)
+(add-hook 'jabber-alert-muc-hooks #'jabber-init-stumpwm-echo)
(add-hook 'jabber-chat-mode-hook #'visual-line-mode)
(add-hook 'jabber-roster-mode-hook #'jabber-init-roster-mode-func)
(add-hook 'jabber-alert-presence-hooks