Skip to main content

Flexible parameter management

Project description

Milieu
======

Milieu allows easy parameter configuration using environment variables or
json files.

Usage Examples
==============

The following code creates a milieu instance that reads environment variables,
then reads the WORKON_HOME variable.

```
>>> import milieu
>>> M = milieu.init()
>>> M.WORKON_HOME
'/Users/andres/.virtualenvs'
```

The following code create a milieu instance from a json file, the reads the
several variables variable:

```
>>> import milieu
>>> M= milieu.init(path='/tmp/file.json')
>>> M.foo
u'fizz'
>>> M.bar
u'buzz'
>>> M.baz
[u'one', u'two', u'three']
```

The json associated to this example is:

```
{
"foo": "fizz",
"bar": "buzz",
"baz": ["one", "two", "three"]
}
```

Project details


Release history Release notifications

This version

1.0.0

Download files

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

Files for unholster.milieu, version 1.0.0
Filename, size File type Python version Upload date Hashes
Filename, size unholster.milieu-1.0.0-py2.7.egg (6.3 kB) File type Egg Python version 2.7 Upload date Hashes View hashes
Filename, size unholster.milieu-1.0.0.tar.gz (4.2 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page