Skip to content

Latest commit

 

History

History
56 lines (38 loc) · 1.87 KB

README.md

File metadata and controls

56 lines (38 loc) · 1.87 KB

What is configargparser?

There are three main ways that programs get data from their environment when they start up:

  1. Commandline arguments,
  2. Configuration files
  3. Environment variables

Currently, if a python program wants to parse data from these sources, it needs to first check the environment variables, then check for a configuration file and finally look at the commandline arguments. The general cascade is that commandline arguments should override config files which should override environment variables. Unfortunately, checking all of these places is a major pain -- which is what configargparser is meant to address.

Installation

Installation should be straight forward:

To install via pip:

pip install configargparser

To install from source:

python setup.py install

TODO

This implementation is still incomplete. Here's a partial TODO list:

Conform to documented behavior

  • (easy) Write a function that figures out dest from args in add_argument, instead of relying on the Action object

Less Easy Stuff…

I haven't tried any of this yet. It's unlikely—but still possible!—that it could just work…