Skip to main content

Python command-line parsing library

Project description

The argparse module provides an easy, declarative interface for creating command line tools, which knows how to:

  • parse the arguments and flags from sys.argv

  • convert arg strings into objects for your program

  • format and print informative help messages

  • and much more…

The argparse module improves on the standard library optparse module in a number of ways including:

  • handling positional arguments

  • supporting sub-commands

  • allowing alternative option prefixes like + and /

  • handling zero-or-more and one-or-more style arguments

  • producing more informative usage messages

  • providing a much simpler interface for custom types and actions

The latest version of argparse, along with API documentation and examples can be found at:

http://code.google.com/p/argparse/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

argparse-1.0.zip (145.6 kB view details)

Uploaded Source

File details

Details for the file argparse-1.0.zip.

File metadata

  • Download URL: argparse-1.0.zip
  • Upload date:
  • Size: 145.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for argparse-1.0.zip
Algorithm Hash digest
SHA256 8691a050f2600a218cb0ef47c488c3fd431374a22e87b3dd1f6c79edf21c1e0e
MD5 8b1ab70277ff87ea2eca57752472dc8c
BLAKE2b-256 03a2023628577e07f3068ae83c44902beb9bf11ac25839a26b35a591cd0886d2

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page