From 6127a66c6e171487f25a3443b7d0a3a4ef79cdee Mon Sep 17 00:00:00 2001 From: Amar Takhar Date: Tue, 1 Dec 2009 01:13:45 +0000 Subject: [PATCH] Add a customer mail message format, far more useful than the default. Originally committed to SVN as r3837. --- devel/tinderbox/buildbot/master/master.cfg | 45 ++++++++++++++++++++-- 1 file changed, 42 insertions(+), 3 deletions(-) diff --git a/devel/tinderbox/buildbot/master/master.cfg b/devel/tinderbox/buildbot/master/master.cfg index 5b0c0ca06..ea803964e 100644 --- a/devel/tinderbox/buildbot/master/master.cfg +++ b/devel/tinderbox/buildbot/master/master.cfg @@ -428,7 +428,7 @@ fosx_ppc.addStep(shell.ShellCommand( WithProperties("--with-build-credit=BuildBot: %s (%s)", "buildername", "slavename"), "--with-apple-opengl-framework", "--with-wx-config=/Users/verm/prefix/lib/wx/config/osx_cocoa-unicode-debug-2.9", - "--enable-debug", + "--enable-debug" "--prefix=/Users/verm/i", "--disable-check-wx-opengl", "--disable-check-wx-stc", @@ -446,6 +446,7 @@ fosx_ppc.addStep(shell.ShellCommand( 'LUA_LDFLAGS': '-L/Users/verm/prefix/lib/lua51 -llua', 'OPENAL_CFLAGS': '-framework OpenAL', 'OPENAL_LIBS': '-framework OpenAL', + 'CFLAGS': '-I/Developer/SDKs/MacOSX10.5.sdk/usr/include', 'ICONV_LDFLAGS': '/usr/lib/libiconv.dylib', }, name = "configure", @@ -744,11 +745,49 @@ c['status'] = [] from buildbot.status import html c['status'].append(html.WebStatus(http_port="tcp:8001:interface=127.0.0.1", allowForce=1)) + # Send out status emails. from buildbot.status import mail +from buildbot.status.builder import Results +def message(attrs): + text = list() + + text.append("STATUS : %s" % attrs['result'].title()) + text.append("REVISION : %s" % attrs['revision']) + text.append("BUILD URL : %s" % attrs['buildURL']) + text.append("COMMITTERS : %s" % ' '.join(sorted(attrs['responsibleUsers']))) + text.append("") + text.append("LOG FILES") + for log in attrs['logs']: + name, url, lines, logstatus = log + text.append(" %s (%s):\n %s" % (name, Results[logstatus], url)) + text.append("") + + if attrs['changes']: + text.append("CHANGES") + + for change in attrs['changes']: + text.append(" Committer : %s" % change.who) + text.append(" Revision : %s http://devel.aegisub.org/changeset/$s" % (change.revision, change.revision)) + text.append(" Changeset : http://devel.aegisub.org/changeset/$s" % change.revision) + text.append(" Time : %s" % change.when) + text.append("") + text.append(" Files") + for file in change.files: + text.append(" %s" % file) + text.append("Log:\n%s" % change.comments) + text.append("") + text.append("") + + text.append("- %s" % attrs['buildbotURL']) + return ("\n".join(text), 'plain') + c['status'].append(mail.MailNotifier(fromaddr="tinderbox@aegisub.org", - extraRecipients=["aegisub@darkbeer.org"], - sendToInterestedUsers=False)) + extraRecipients=["aegisub-tinderbox@aegisub.org"], + sendToInterestedUsers=False, + customMesg=message, + mode="all", + extraHeaders={'Reply-To':'aegisub-tinderbox@aegisub.org'})) # IRC! from buildbot.status import words