From 981902a764e15d4555066e30660e91b0159e6ccb Mon Sep 17 00:00:00 2001 From: Paul Sbarra Date: Thu, 17 Oct 2013 15:08:44 -0500 Subject: [PATCH] git_pillar: Don't merge updates When updating the local cached repository don't try to pull/merge the changes as the operation will fail if merge conflicts exist. We only want to mirror what's in the remote repository. --- salt/pillar/git_pillar.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/salt/pillar/git_pillar.py b/salt/pillar/git_pillar.py index 495b7a9884..3dc9785915 100644 --- a/salt/pillar/git_pillar.py +++ b/salt/pillar/git_pillar.py @@ -97,11 +97,10 @@ def update(branch, repo_location): pid = os.getpid() repo = init(branch, repo_location) try: - repo.git.checkout(branch) + repo.git.checkout("origin/" + branch) except git.exc.GitCommandError as e: logging.error('Unable to checkout branch {0}: {1}'.format(branch, e)) return False - repo.git.pull() return True