feat(config): implement diff mode support
This commit is contained in:
parent
711dfc3ff6
commit
13089df638
1 changed files with 2 additions and 2 deletions
|
@ -128,9 +128,9 @@ def iter_system(module, result, tree=None, value=None):
|
|||
result['changed'] = True
|
||||
stjoined = ' => '.join(subtree)
|
||||
if old_value is not None:
|
||||
result['diff'][0]['before'] += 'system => {} => {}\n'.format(app, stjoined, old_value)
|
||||
result['diff'][0]['before'] += 'system => {} => {}\n'.format(stjoined, old_value)
|
||||
if v is not None:
|
||||
result['diff'][0]['after'] += 'system => {} => {}\n'.format(app, stjoined, v)
|
||||
result['diff'][0]['after'] += 'system => {} => {}\n'.format(stjoined, v)
|
||||
|
||||
if not module.check_mode:
|
||||
# Remove key if the new value is none
|
||||
|
|
Loading…
Reference in a new issue