Growl 1.3 ã«ããã growlnotifiy ã³ãã³ã使ããªããªã£ã¦ QuickJUnit ã®çµæãåå¾ã§ããªãããèªåã§ç¨æãã
Growl 1.3 㧠lion ã«æ£å¼å¯¾å¿ã§ã¤ãã¿ã¼ã¼ã¼ã¼ï¼ï¼ï¼ã¨æã£ãã
ãææåãã§ã¤ã¤ã¼ã¼ã³ã¨ãæã£ãã
é¢å¸æã®å±¥æ´è¡¨ç¤ºã¨ãã§ãå
¨ç¶å®ãè²·ãç©ã ã£ãã¤ãã¿ã¼ã¼ã¼ã¼ï¼ï¼ï¼ã¨æã£ãã
growlnotifiy ã³ãã³ã使ããªãã¦ã¤ã¤ã¼ã¼ã³ â ã¤ãã³ã³
ã¨ããããã§ãã¨ãããã QuickJUnit ã®çµæãéç¥ãããªãã®ã¯æ»æ´»åé¡ãªã®ã§æ¸ããã
gntp 使ã£ã¦ãã®ã§
$ sudo eazy_install gntp
ãã¦ä½¿ã£ã¦ãã ããã
#!/usr/bin/env python # -*- coding: utf-8 -*- import gntp.notifier import sys applicationIcon = 'http://cdn-ak.f.st-hatena.com/images/fotolife/k/kompiro/20100811/20100811151901.png' notifications = ['OK','Failure','Error'] okIcon = 'https://github.com/kompiro/quick-junit/blob/master/junit.extensions.eclipse.quick.notifications/icons/tsuiteok.gif?raw=true' failIcon = 'https://github.com/kompiro/quick-junit/raw/master/junit.extensions.eclipse.quick.notifications/icons/tsuitefail.gif' errorIcon = 'https://github.com/kompiro/quick-junit/blob/master/junit.extensions.eclipse.quick.notifications/icons/tsuiteerror.gif?raw=true' growl = gntp.notifier.GrowlNotifier( applicationName = 'QuickJUnitGrowlNotifir.py', notifications = notifications, defaultNotifications = notifications, applicationIcon = applicationIcon, ) growl.register() if __name__ == '__main__': argvs = sys.argv argc = len(argvs) if argc != 2 : print '''Usage: # python %s QuickJunitDetail template is ${results},${name},${error_counts},${fail_counts},${ok_counts},${total_counts} ''' % argvs[0] quit() results = argvs[1].strip('"').split(',') description = 'OK:%s FAIL:%s ERROR:%s TOTAL:%s' % tuple(results[2:]) noteType = results[0] icon = okIcon if noteType == 'Failure': icon = failIcon elif noteType == 'Error': icon = errorIcon growl.notify( noteType = noteType, title = results[1], description = description, icon = icon, )
ããã§ã
Eclipse ã®æ¹ã§
ããã°
ã«ãªãã¾ãã
ã®è¨å®ãåæ ãããªãã®ãªãã§ã ããï¼ï¼