get config filename from env variable RADICALE_CONFIG

This commit is contained in:
Roberto De Ioris 2011-06-07 17:44:53 +02:00
parent b7a61d5c0c
commit 4bd425608d

View File

@ -74,6 +74,8 @@ for section, values in INITIAL_CONFIG.items():
_CONFIG_PARSER.read("/etc/radicale/config") _CONFIG_PARSER.read("/etc/radicale/config")
_CONFIG_PARSER.read(os.path.expanduser("~/.config/radicale/config")) _CONFIG_PARSER.read(os.path.expanduser("~/.config/radicale/config"))
if os.environ.get('RADICALE_CONFIG', None):
_CONFIG_PARSER.read(os.environ['RADICALE_CONFIG'])
# Wrap config module into ConfigParser instance # Wrap config module into ConfigParser instance
sys.modules[__name__] = _CONFIG_PARSER sys.modules[__name__] = _CONFIG_PARSER