Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

docopt wrapper adding config file and environment variable support.

Project Description

Love using docopt over argparse or Click? Wish it took care of environment variables and/or config files?

docoptcfg is a wrapper for docopt which handles reading configuration data from environment variables and/or an INI/INF configuration file. You can (1) enable only the environment variable part, (2) only the config file part, (3) or use both at the same time:

  1. args = docoptcfg(__doc__, env_prefix='MYAPP_')
  2. args = docoptcfg(__doc__, config_option='--config')
  3. args = docoptcfg(__doc__, config_option='--config', env_prefix='MYAPP_')

📖 Full documentation: https://docoptcfg.readthedocs.org

  • Python 2.6, 2.7, PyPy, PyPy3, 3.3, 3.4, and 3.5 supported on Linux and OS X.
  • Python 2.7, 3.3, 3.4, and 3.5 supported on Windows (both 32 and 64 bit versions of Python).

Quickstart

Install:

pip install docoptcfg

Changelog

This project adheres to Semantic Versioning.

1.0.2 - 2016-06-28

Fixed
  • Bug where docoptcfg failed to handle positional arguments with repeating args/opts.

1.0.1 - 2016-01-25

Fixed
  • setup.py was previously configured for packages, not modules.

1.0.0 - 2016-01-25

  • Initial release.
Release History

Release History

This version
History Node

1.0.2

History Node

1.0.1

History Node

1.0.0

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
docoptcfg-1.0.2.tar.gz (5.3 kB) Copy SHA256 Checksum SHA256 Source Jun 29, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting