diff options
author | Michael Fenn <fennm@deshawresearch.com> | 2013-03-29 11:09:50 -0400 |
---|---|---|
committer | Michael Fenn <fennm@deshawresearch.com> | 2013-03-29 11:09:50 -0400 |
commit | 773d9aaffe82a24146d8b26bf9e8e122c0ec5768 (patch) | |
tree | 80b3a951a363f949389046c0c96c32d2984d3ca1 /src/lib/Bcfg2 | |
parent | 3892fa0f0c5214f231cb75a76384f24a92bdbc1d (diff) | |
download | bcfg2-773d9aaffe82a24146d8b26bf9e8e122c0ec5768.tar.gz bcfg2-773d9aaffe82a24146d8b26bf9e8e122c0ec5768.tar.bz2 bcfg2-773d9aaffe82a24146d8b26bf9e8e122c0ec5768.zip |
Promote bcfg2-info to have it's own Options dict
Turns out that CLIENT_COMMON_OPTIONS and SERVER_COMMON_OPTIONS
conflict. Adding ppath and max_copies (turns out the latter is also
necessary) to the bcfg2-info code directly seemed like a maintenance
problem waiting to happen, so I factored that out into a new
INFO_COMMON_OPTIONS dict. That will keep any options parsing special
cases out of the bcfg2-info code hopefully be more maintainable
going forward.
Diffstat (limited to 'src/lib/Bcfg2')
-rw-r--r-- | src/lib/Bcfg2/Options.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/Bcfg2/Options.py b/src/lib/Bcfg2/Options.py index 7c91ca3cc..3197d2682 100644 --- a/src/lib/Bcfg2/Options.py +++ b/src/lib/Bcfg2/Options.py @@ -1269,6 +1269,10 @@ TEST_COMMON_OPTIONS = dict(noseopts=TEST_NOSEOPTS, xunit=TEST_XUNIT, validate=CFG_VALIDATION) +INFO_COMMON_OPTIONS = dict(ppath=PARANOID_PATH, + max_copies=PARANOID_MAX_COPIES) +INFO_COMMON_OPTIONS.update(CLI_COMMON_OPTIONS) +INFO_COMMON_OPTIONS.update(SERVER_COMMON_OPTIONS) class OptionParser(OptionSet): """ |