mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-13 09:33:50 +00:00
[lit] Add --version option.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203496 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
55aa019282
commit
a99759357a
@ -136,6 +136,9 @@ def main(builtinParameters = {}):
|
||||
from optparse import OptionParser, OptionGroup
|
||||
parser = OptionParser("usage: %prog [options] {file-or-path}")
|
||||
|
||||
parser.add_option("", "--version", dest="show_version",
|
||||
help="Show version and exit",
|
||||
action="store_true", default=False)
|
||||
parser.add_option("-j", "--threads", dest="numThreads", metavar="N",
|
||||
help="Number of testing threads",
|
||||
type=int, action="store", default=None)
|
||||
@ -228,6 +231,10 @@ def main(builtinParameters = {}):
|
||||
|
||||
(opts, args) = parser.parse_args()
|
||||
|
||||
if opts.show_version:
|
||||
print "lit %s" % (lit.__version__,)
|
||||
return
|
||||
|
||||
if not args:
|
||||
parser.error('No inputs specified')
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user