Implement --diff for the copy module.

This commit is contained in:
Stoned Elipot 2013-02-25 23:32:52 +01:00
parent f6e3583b9b
commit 10e9f1fc1e
8 changed files with 91 additions and 27 deletions

View file

@ -454,6 +454,7 @@ class AnsibleModule(object):
kwargs['state'] = 'file'
if HAVE_SELINUX and self.selinux_enabled():
kwargs['secontext'] = ':'.join(self.selinux_context(path))
kwargs['size'] = st[stat.ST_SIZE]
else:
kwargs['state'] = 'absent'
return kwargs