multiconf.envs module

class multiconf.envs.EnvFactory[source]
Env(name, allow_todo=False)[source]

Declare a new Env

EnvGroup(name, *members)[source]

Declare a new EnvGroup

config(env, allow_todo=False)[source]

Retreive the configuration for the specified env.

NOTE, There can only be one current config! It is possible to call ‘config’ multiple times, but storing references to items in the configuration, and accessing attributes at a later time, will return the value from the last env.

Parameters:allow_todo (bool) – If true, then retreiving a configuration for an env which contains MC_TODO values will not raise an error.

Return (Root ConfigItem proxy): Reference to the config with the current env set to env.

env(name)[source]

Get an already declared env from it’s name

env_or_group_from_name(name)[source]

Get an already declared env or group from it’s name