manual: script cmd line params updated

This commit is contained in:
Milanka Ringwald 2015-04-24 10:07:14 +02:00
parent 4b0c7d42c3
commit fb280584a9
2 changed files with 6 additions and 6 deletions

View File

@ -5,7 +5,7 @@ pdf: clean
open btstack_gettingstarted.pdf
example:
./update_listings.py -s 1
./update_listings.py -s
subl examples.tex
pdflatex examples.tex
open examples.pdf

View File

@ -266,16 +266,16 @@ def main(argv):
standalone_flag = 0
try:
opts, args = getopt.getopt(argv,"hs:o:",["sflag=","ofile="])
opts, args = getopt.getopt(argv,"hso:",["standalone","ofile="])
except getopt.GetoptError:
print 'test.py [-s <standaloneflag>] [-o <outputfile>]'
print 'test.py [-s] [-o <outputfile>]'
sys.exit(2)
for opt, arg in opts:
if opt == '-h':
print 'update_listings.py [-s <standalone_flag>] [-o <outputfile>]'
print 'update_listings.py [-s] [-o <outputfile>]'
sys.exit()
elif opt in ("-s", "--sflag"):
standalone_flag = arg
elif opt in ("-s", "--standalone"):
standalone_flag = 1
elif opt in ("-o", "--ofile"):
outputfile = arg
print 'Standalone flag is ', standalone_flag