blob: f190f94ae6824c4d3ba37a6882caae1ec7206fe8 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
gnus-desktop-notify.el: Gnus Desktop Notification global minor mode
===================================================================
.. contents::
Desktop notification integration in `Gnus <http://www.gnus.org/>`_!? `Ohh
goody!`
Basic setup
-----------
``gnus-desktop-notify.el`` provides a simple mechanism to notify the user when
new messages are received. For basic usage, to be used in conjunction with
``gnus-daemon``, put the following:
.. code:: scm
(require 'gnus-desktop-notify)
(gnus-desktop-notify-mode)
(gnus-demon-add-scanmail)
into your ``.gnus`` file. The default is to use alert_ if available, which
works on every operating system and allows the user to customize the
notification through emacs. See https://github.com/jwiegley/alert#for-users for
further info. If not available, the ``notifications`` library (part of emacs >=
24) is used, so no external dependencies are required. With emacs <= 23 instead
the generic ``notify-send`` program is used, which (in Debian or Ubuntu) is
available in the ``libnotify-bin`` package.
You can also call any program directly by changing the
``gnus-desktop-notify-exec-program`` variable, or change the behavior entirely
by setting a different ``gnus-desktop-notify-function`` function.
The group names are collapsed by default, and a single notification is
generated containing all the groups with a count of new messages.
Mac setup
---------
If alert_ is available, growl_ notifications are generated by default. No setup
is required! See the ``alert`` customization group to tweak the generated
messages to your liking.
You can also download and install growl_ manually, and then customize as
follows:
.. code:: scm
(require 'gnus-desktop-notify)
(setq gnus-desktop-notify-function 'gnus-desktop-notify-exec
gnus-desktop-notify-exec-program "growlnotify -a Emacs.app -m")
(gnus-desktop-notify-mode)
(gnus-demon-add-scanmail)
Advanced setup
--------------
By default, all groups are notified when new messages are received. You can
exclude a single group by setting the ``group-notify`` group parameter to
"t" (this is quite common for spammy groups).
You can also selectively monitor groups instead by changing the
``gnus-desktop-notify-groups`` variable to ``'gnus-desktop-notify-explicit``
and then manually selecting which groups to include the same way.
Press "``G c``" in the group buffer to customize group parameters
interactively.
See the ``gnus-desktop-notify`` customization group for more details.
.. _alert: https://github.com/jwiegley/alert
.. _growl: http://growl.info/
|