From 3e09de7aefc17308d3f0dacae1c7038e585770ff Mon Sep 17 00:00:00 2001 From: Toshio Kuratomi Date: Wed, 19 Nov 2014 12:30:24 -0800 Subject: [PATCH] Fix git module checking out correct version after initial clone Fixes #313 --- lib/ansible/modules/source_control/git.py | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ansible/modules/source_control/git.py b/lib/ansible/modules/source_control/git.py index 998e684afb1..17378fc97b6 100644 --- a/lib/ansible/modules/source_control/git.py +++ b/lib/ansible/modules/source_control/git.py @@ -646,6 +646,7 @@ def main(): module.exit_json(changed=True, before=before, after=remote_head) # there's no git config, so clone clone(git_path, module, repo, dest, remote, depth, version, bare, reference, recursive) + repo_updated = True elif not update: # Just return having found a repo already in the dest path # this does no checking that the repo is the actual repo