enable notification on linux with pynotify/libnotify #23

solsticedhiver opened this Issue Mar 11, 2010 · 1 comment


None yet

2 participants


by loooking carefully at the default settings.py I noticed a setting to enable growl notification.

so i added a few lines here and there to enable notification via pynotify (which uses libnotify)

This is not really an important feature ;-)

one can use PYNOTIFY = True in settings.py and install pynotify
--- a/hydeengine/init.py
+++ b/hydeengine/init.py
@@ -25,6 +25,13 @@ from file_system import File, Folder
from path_util import PathUtil
from processor import Processor
from siteinfo import SiteInfo
+ import pynotify
+ if not pynotify.init('Hyde'):
+ PYNOTIFY = False
+except ImportError:
+ PYNOTIFY = False

 class _HydeDefaults:

@@ -248,6 +255,8 @@ class Generator(object):
                 subprocess.call([settings.GROWL, "-n", "Hyde", "-t", title, "-m", message])        
+        if hasattr(settings, "PYNOTIFY") and settings.PYNOTIFY and PYNOTIFY:
+            pynotify.Notification(title, message, None).show()

     def pre_process(self, node):

None is for the icon as there is none for hyde ???


Nice. Will add in the patch.

Hyde has an icon. I should probably add it to the Hyde repository ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment