X-Git-Url: http://rtime.felk.cvut.cz/gitweb/can-benchmark.git/blobdiff_plain/bb9ef76d74d6c1e6d1c5b156c660003a2811a182..fc0d7a8b33c57f63cbb15f7305c55cb287626bc2:/gw-tests/genhtml/genhtml.py diff --git a/gw-tests/genhtml/genhtml.py b/gw-tests/genhtml/genhtml.py index 2488c85..a5114f1 100755 --- a/gw-tests/genhtml/genhtml.py +++ b/gw-tests/genhtml/genhtml.py @@ -6,8 +6,10 @@ import sys; import urllib import traceback import glob +import datetime -html_copyright = """
Authors: Michal Sojka, Pavel Píša, Copyright © 2010, 2011 Czech Technical University in Prague
""" +html_copyright = """
Authors: Michal Sojka, Pavel Píša, Martin Hořeňovský, Copyright © 2010-%d Czech Technical University in Prague.
+Creative Commons License This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
""" % datetime.date.today().year class DimValue(object): def __new__(cls, dim, value): @@ -156,11 +158,12 @@ class Test(object): print >>file, "" % \ (urllib.quote(self.path), urllib.quote(self.path), img) def fullImgLink(self, pngName): + ps = "Plot source" % ("plot"+pngName[5:-4]+".gp") if 'NO_PDF' in os.environ: - return "
" % pngName + return "
%s
" % (pngName, ps) else: - return "
" % \ - (pngName[:-4]+".pdf", pngName) + return "
%s
" % \ + (pngName[:-4]+".pdf", pngName, ps) def htmlPrintStats(self, html): cwd = os.getcwd() @@ -333,7 +336,7 @@ h4 { margin: 0; } print test.path test.generateHtml() - os.system("source-highlight -d --output-dir=. ../*.sh > /dev/null") + os.system("source-highlight -d --output-dir=. %s/*.sh > /dev/null" % sh_dir) class Page(object): def __init__(self, dimPair, valsOther, tests): @@ -406,6 +409,7 @@ class Page(object): if __name__ == "__main__": os.chdir(sys.argv[1]) + sh_dir = sys.argv[2] os.system("rm *.html") tests = Tests("./", Space(DimensionHostKern(), DimensionKern(), DimensionTraffic(), DimensionLoad(), DimensionTest())) tests.generateHtml()