Skip to content

Instantly share code, notes, and snippets.

@yoshiori
Created June 14, 2011 07:25
Show Gist options
  • Save yoshiori/1024470 to your computer and use it in GitHub Desktop.
Save yoshiori/1024470 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
import pynotify
def main():
if len(sys.argv) is not 3:
return
summary = sys.argv[1];
detail = sys.argv[2];
img = "dialog-info"
print summary
if summary not in 'Quick JUnit Test OK':
img = "dialog-warning"
n = pynotify.Notification(summary, detail, img)
n.show()
if __name__ == '__main__':
main();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment