From 49f5b28fbdeffed31e6534f73ff9fc4f04dec1f4 Mon Sep 17 00:00:00 2001 From: Toshio Kuratomi Date: Wed, 28 Jan 2015 16:26:44 -0800 Subject: [PATCH] Change the git force parameter to default to no as a safety change. Fixes #306 --- lib/ansible/modules/source_control/git.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/ansible/modules/source_control/git.py b/lib/ansible/modules/source_control/git.py index 44ebf06487a..0cb87304a92 100644 --- a/lib/ansible/modules/source_control/git.py +++ b/lib/ansible/modules/source_control/git.py @@ -93,13 +93,14 @@ options: An example value could be "refs/meta/config". force: required: false - default: "yes" + default: "no" choices: [ "yes", "no" ] version_added: "0.7" description: - If C(yes), any modified files in the working repository will be discarded. Prior to 0.7, this was always - 'yes' and could not be disabled. + 'yes' and could not be disabled. Prior to 1.9, the default was + `yes` depth: required: false default: null @@ -611,7 +612,7 @@ def main(): remote=dict(default='origin'), refspec=dict(default=None), reference=dict(default=None), - force=dict(default='yes', type='bool'), + force=dict(default='no', type='bool'), depth=dict(default=None, type='int'), clone=dict(default='yes', type='bool'), update=dict(default='yes', type='bool'),