Lines Matching refs:argparse
9 This tutorial is intended to be a gentle introduction to :mod:`argparse`, the
11 This was written for argparse in Python 3. A few details are different in 2.x,
19 Note also that :mod:`argparse` is based on :mod:`optparse`,
76 import argparse
77 parser = argparse.ArgumentParser()
102 * The second one starts to display the usefulness of the :mod:`argparse`
116 import argparse
117 parser = argparse.ArgumentParser()
151 * The variable is some form of 'magic' that :mod:`argparse` performs for free
161 import argparse
162 parser = argparse.ArgumentParser()
182 import argparse
183 parser = argparse.ArgumentParser()
198 That didn't go so well. That's because :mod:`argparse` treats the options we
200 :mod:`argparse` to treat that input as an integer::
202 import argparse
203 parser = argparse.ArgumentParser()
229 import argparse
230 parser = argparse.ArgumentParser()
274 import argparse
275 parser = argparse.ArgumentParser()
320 import argparse
321 parser = argparse.ArgumentParser()
349 import argparse
350 parser = argparse.ArgumentParser()
383 import argparse
384 parser = argparse.ArgumentParser()
417 import argparse
418 parser = argparse.ArgumentParser()
457 import argparse
458 parser = argparse.ArgumentParser()
523 import argparse
524 parser = argparse.ArgumentParser()
561 import argparse
562 parser = argparse.ArgumentParser()
592 The :mod:`argparse` module is very powerful,
602 import argparse
603 parser = argparse.ArgumentParser()
641 import argparse
642 parser = argparse.ArgumentParser()
671 :class:`argparse.ArgumentParser` instance. Let's introduce a third one,
678 import argparse
680 parser = argparse.ArgumentParser()
721 import argparse
723 parser = argparse.ArgumentParser(description="calculate X to the power of Y")
763 The :mod:`argparse` module offers a lot more than shown here.