[llvm-commits] [zorg] r150741 - /zorg/trunk/lnt/lnt/util/NTEmailReport.py
Daniel Dunbar
daniel at zuster.org
Thu Feb 16 14:54:08 PST 2012
Author: ddunbar
Date: Thu Feb 16 16:54:07 2012
New Revision: 150741
URL: http://llvm.org/viewvc/llvm-project?rev=150741&view=rev
Log:
[lnt] lnt.util.NTEmailReport: Drop main(), this file is only used as a module
now.
Modified:
zorg/trunk/lnt/lnt/util/NTEmailReport.py
Modified: zorg/trunk/lnt/lnt/util/NTEmailReport.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/lnt/lnt/util/NTEmailReport.py?rev=150741&r1=150740&r2=150741&view=diff
==============================================================================
--- zorg/trunk/lnt/lnt/util/NTEmailReport.py (original)
+++ zorg/trunk/lnt/lnt/util/NTEmailReport.py Thu Feb 16 16:54:07 2012
@@ -1,11 +1,3 @@
-#!/usr/bin/python
-
-"""
-Command line tool for sending an LNT email report.
-"""
-
-# FIXME: Roll into lnttool or just kill?
-
import os
import smtplib
import sys
@@ -23,22 +15,6 @@
from lnt.db.perfdb import Run, Sample
-def main():
- global opts
- from optparse import OptionParser
- parser = OptionParser("usage: %prog database run-id baseurl sendmail-host from to")
- opts,args = parser.parse_args()
-
- if len(args) != 6:
- parser.error("incorrect number of argments")
-
- dbpath,runID,baseurl,host,from_,to = args
-
- db = lnt.db.perfdb.PerfDB(dbpath)
- run = db.getRun(int(runID))
-
- emailReport(db, run, baseurl, host, from_, to)
-
def emailReport(result, db, run, baseurl, email_config, to, was_added=True,
will_commit=True):
import email.mime.multipart
@@ -646,6 +622,3 @@
# FIXME: Where is the old mailer getting the arch from?
subject = """%s nightly tester results""" % machine.name
return subject, report.getvalue(), None
-
-if __name__ == '__main__':
- main()
More information about the llvm-commits
mailing list