From ce5f326f11a3032a710074e65bba06246e069c6b Mon Sep 17 00:00:00 2001 From: Nathan Binkert Date: Tue, 18 Oct 2005 19:17:36 -0400 Subject: [PATCH] Default jobfile for stats util/stats/stats.py: Make the default jobfile Test.py in the current directory add the -J flag to tell it not to use a jobfile --HG-- extra : convert_revision : 5cf5bb2f32ed9c9701a94eabc9b2a538581acf94 --- util/stats/stats.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/util/stats/stats.py b/util/stats/stats.py index c53d77d54..af9ae5575 100755 --- a/util/stats/stats.py +++ b/util/stats/stats.py @@ -465,10 +465,11 @@ if __name__ == '__main__': options.graph = False options.ticks = False options.printmode = 'G' + jobfilename = 'Test.py' options.jobfile = None options.all = False - opts, args = getopts(sys.argv[1:], '-BEFG:ad:g:h:j:pr:s:u:T:') + opts, args = getopts(sys.argv[1:], '-BEFG:Jad:g:h:j:pr:s:u:T:') for o,a in opts: if o == '-B': options.binned = True @@ -487,8 +488,10 @@ if __name__ == '__main__': options.graphdir = a if o == '-h': options.host = a + if o == '-J': + jobfilename = None if o == '-j': - options.jobfile = JobFile(a) + jobfilename = a if o == '-p': options.passwd = getpass.getpass() if o == '-r': @@ -500,7 +503,8 @@ if __name__ == '__main__': if o == '-T': options.ticks = a - if options.jobfile: + if jobfilename: + options.jobfile = JobFile(jobfilename) if not options.host: options.host = options.jobfile.dbhost if not options.db: -- 2.30.2