5 from __future__
import print_function
6 import shutil, sys, os, valtools
8 from optparse
import OptionParser
13 parser = OptionParser()
14 parser.usage =
"usage: %prog" 16 parser.add_option(
"-e",
"--extension", dest=
"extension",
17 help=
"adds an extension to the name of this benchmark",
20 parser.add_option(
"-f",
"--force", dest=
"force",action=
"store_true",
21 help=
"force the submission. Be careful!",
25 (options,args) = parser.parse_args()
37 print(
'submitting from local: ', localBench)
40 comparisons = website.listComparisons( bench )
41 if len(comparisons)>0:
42 print(
'You are about to make the following list of comparison pages obsolete. These pages will thus be removed:')
46 while answer !=
'y' and answer !=
'n':
47 answer = raw_input(
'do you agree? [y/n]')
54 bench.makeRelease( website )
57 if bench.exists( website ) ==
True:
58 if options.force ==
False:
59 print(
'please use the -e option to choose another extension')
60 print(
' e.g: submit.py -e Feb10')
64 print(
'overwriting...')
65 shutil.rmtree(bench.benchmarkOnWebSite(website))
70 shutil.copytree(localBench.fullName(), bench.benchmarkOnWebSite(website) )
71 print(
'done. Access your benchmark here:')
72 print(bench.benchmarkUrl( website ))
76 for comparison
in comparisons:
77 rm =
'rm -rf '+comparison
S & print(S &os, JobReport::InputFile const &f)