diff options
author | skvidal <skvidal> | 2006-05-14 04:48:11 +0000 |
---|---|---|
committer | skvidal <skvidal> | 2006-05-14 04:48:11 +0000 |
commit | 2a84506fa40715b94207379e3b3caf030b010c69 (patch) | |
tree | cf5d007569bf73f559aae5cfe824e5db081e0e33 | |
parent | e93b34bd0e792798c96909bd1ea90010fc165c43 (diff) | |
download | mock-2a84506fa40715b94207379e3b3caf030b010c69.tar.gz mock-2a84506fa40715b94207379e3b3caf030b010c69.tar.xz mock-2a84506fa40715b94207379e3b3caf030b010c69.zip |
check in global defaults patch from Andreas Thienemann
-rw-r--r-- | etc/defaults.cfg | 8 | ||||
-rw-r--r-- | mock.py | 8 |
2 files changed, 16 insertions, 0 deletions
diff --git a/etc/defaults.cfg b/etc/defaults.cfg new file mode 100644 index 0000000..21e7d4a --- /dev/null +++ b/etc/defaults.cfg @@ -0,0 +1,8 @@ +# mock defaults +# +# Define default values here. +# These values are overwritten in the /etc/mock/CHROOT.cfg files. +# +# Example: +# +# config_opts['foo'] = bar @@ -735,6 +735,14 @@ def main(): if options.configdir: config_path = options.configdir + # Read in the default values which can be overwritten + # with the more specific config being loaded below. + cfg = os.path.join(config_path, 'defaults.cfg') + if os.path.exists(cfg): + execfile(cfg) + else: + pass # not finding the defaults.cfg file is no error + # read in the config file by chroot name if options.chroot.endswith('.cfg'): cfg = '%s/%s' % (config_path, options.chroot) |