From 45c98655e184563ed176b7a2b6f8dadd50610873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Gl=C3=BCpker?= Date: Sun, 13 Jan 2019 19:53:05 +0100 Subject: Cleanup unused variable --- updateGit.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'updateGit.py') diff --git a/updateGit.py b/updateGit.py index de1bbc5..648176b 100755 --- a/updateGit.py +++ b/updateGit.py @@ -53,7 +53,6 @@ def findChanges(statusoutput): def updatePath(path): friendly_path = os.path.basename(path) dPrint('Repository:', path) - head = getGitStdout(path, 'rev-parse --abbrev-ref HEAD') changed = findChanges(getGitStdout(path, 'status --porcelain')) cur_branch = getGitStdout(path, 'rev-parse --abbrev-ref HEAD') @@ -126,7 +125,7 @@ def updatePath(path): # print('Safe branch:', safe_branch) # Checkout master, if detached HEAD and not proceeded - if head == 'HEAD': + if cur_branch == 'HEAD': if changed: print('[%s] Head detached, but changes found. Stash them to checkout %s.' % ( friendly_path, -- cgit v1.2.3