From e63182f8e23d5fd95ffd5199acf0ea7ebde3369c Mon Sep 17 00:00:00 2001 From: "aelaguiz@gmail.com" Date: Thu, 8 May 2014 19:00:35 -0500 Subject: [PATCH 1/4] WOrkaround for cwd bug on pull --- git/cmd.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/git/cmd.py b/git/cmd.py index b3274dd8f..83d96fb65 100644 --- a/git/cmd.py +++ b/git/cmd.py @@ -330,6 +330,9 @@ def execute(self, command, cwd = os.getcwd() else: cwd=self._working_dir + + if command[1] == 'pull': + cwd += '/.git' # Start the process proc = Popen(command, From 19a8c58e65f586866451e7584b8e8d94014d3648 Mon Sep 17 00:00:00 2001 From: "aelaguiz@gmail.com" Date: Fri, 9 May 2014 05:49:02 -0500 Subject: [PATCH 2/4] Added reset --- git/cmd.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/git/cmd.py b/git/cmd.py index 83d96fb65..ed34b066c 100644 --- a/git/cmd.py +++ b/git/cmd.py @@ -331,7 +331,7 @@ def execute(self, command, else: cwd=self._working_dir - if command[1] == 'pull': + if command[1] == 'pull' or command[1] == 'reset': cwd += '/.git' # Start the process From 94d2dfc8a2f6b7461a9c12e2e38b9ccbd4253a6d Mon Sep 17 00:00:00 2001 From: "aelaguiz@gmail.com" Date: Fri, 9 May 2014 06:15:47 -0500 Subject: [PATCH 3/4] Fixed env args --- git/cmd.py | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/git/cmd.py b/git/cmd.py index ed34b066c..23c09001d 100644 --- a/git/cmd.py +++ b/git/cmd.py @@ -331,9 +331,17 @@ def execute(self, command, else: cwd=self._working_dir - if command[1] == 'pull' or command[1] == 'reset': - cwd += '/.git' - + import logging + log = logging.getLogger(u"cratejoy") + log.debug(u"Running command {} in {}".format(command, cwd)) + + env = os.environ.copy() + if env.get('GIT_DIR'): + del env['GIT_DIR'] + + #log.debug(env) + #log.debug(u"Args {}".format(subprocess_kwargs)) + # Start the process proc = Popen(command, cwd=cwd, @@ -341,6 +349,7 @@ def execute(self, command, stderr=PIPE, stdout=PIPE, close_fds=(os.name=='posix'),# unsupported on linux + env=env, **subprocess_kwargs ) if as_process: From ae44d474c8a494e10c50e4428b29f17bdf19f741 Mon Sep 17 00:00:00 2001 From: "aelaguiz@gmail.com" Date: Sat, 31 May 2014 20:27:13 -0500 Subject: [PATCH 4/4] WIP --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 5a311b4fc..5721194ee 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.3.2 RC1 +0.3.2 amir