summaryrefslogtreecommitdiffstats
path: root/cholerab/knut/plugs/pynot/index
blob: 04e9c90cf8b35c50aabeb552bd4c3144241c4b85 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/python

import pynotify,os,sys

imageURI = os.path.abspath(os.path.normpath(os.path.dirname(sys.argv[0]) + '/../../../bling/krebs_plain_negate_nobg.png'))
try:
  TITLE=os.environ.get('method','clive') + ':' + os.environ.get('id','-1')
  MESSAGE=os.environ.get('params','No Message')
except:
  print("Error 1: You are made of stupid!")
  exit(23)

pynotify.init("Notif App",)
print imageURI
n = pynotify.Notification(TITLE, MESSAGE,imageURI)
n.set_timeout(20000)
n.show()