[Pkg-ltsp-devel] Bug#575031: Bug#575031: ltspfs: issue KDE popups

Petter Reinholdtsen pere at hungry.com
Mon Jul 5 17:49:38 UTC 2010


[Vagrant Cascadian]
> much less to go on.

Well, enough to have a fighting chance.  I'm testing with this
implementation now.

#!/usr/bin/python
# requires python-notify
import pynotify
import sys
import string
import os
# Do not run on Gnome, as gnome detect the ltspfs mounts on its own.
xdgdirs = os.environ.get('XDG_DATA_DIRS')
if xdgdirs and -1 != xdgdirs.find("/usr/share/gnome"):
  sys.exit(0)
if not pynotify.init("edu-notify"):
  sys.exit(1)
n = pynotify.Notification("ltspfs","%s" % sys.argv[1]+' '+sys.argv[2])
n.show()

> i also suspect that many of the other variables tend to change a lot
> between GNOME releases, so i'd want to know that the environment
> variables would remain consistant for a while, and preferrably work
> across distros...

Sure, that would be nice.  But I am happy with a solution that work
now too, without having to predict what will happen in the future. :)

Happy hacking,
-- 
Petter Reinholdtsen





More information about the Pkg-ltsp-devel mailing list