ansible/ansible — pull request #6949 by sam-at-github (2014-04-11 13:25:50+00:00)
Title: Minor change to cron core module, to unlink cron file if empty.

Currently the cron module will leave an empty file in /etc/cron.d/ if you remove all the cron jobs added to it via ansible. This is sort of confusing and messy if you are adding and removing cron.d/ files alot. May be slightly less efficient in edge case where you remove all cron entries then add some in the same play.

Minor change, but I think it is the more correct behavior to remove the file if it is empty. Note the file is still not removed if it contains non ansible managed cron stuff like env settings.