aboutsummaryrefslogtreecommitdiff
path: root/git/cmd.py
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2015-01-04 13:48:29 +0100
committerSebastian Thiel <byronimo@gmail.com>2015-01-04 13:48:29 +0100
commitc80d727e374321573bb00e23876a67c77ff466e3 (patch)
tree7590d6ae544eac56e83639d27e1f9013b38d8a4b /git/cmd.py
parent965a08c3f9f2fbd62691d533425c699c943cb865 (diff)
downloadGitPython-c80d727e374321573bb00e23876a67c77ff466e3.tar.gz
GitPython-c80d727e374321573bb00e23876a67c77ff466e3.zip
Bumped version, updated changelog, reduced code smell
There is more work to do though, as many imports are still incorrect. Also, there are still print statements
Diffstat (limited to 'git/cmd.py')
-rw-r--r--git/cmd.py16
1 files changed, 9 insertions, 7 deletions
diff --git a/git/cmd.py b/git/cmd.py
index bfdefb17..d024b409 100644
--- a/git/cmd.py
+++ b/git/cmd.py
@@ -334,7 +334,7 @@ class Git(LazyMixin):
If you add additional keyword arguments to the signature of this method,
you must update the execute_kwargs tuple housed in this module."""
if self.GIT_PYTHON_TRACE and (self.GIT_PYTHON_TRACE != 'full' or as_process):
- print ' '.join(command)
+ print(' '.join(command))
# Allow the user to have the command executed in their working dir.
if with_keep_cwd or self._working_dir is None:
@@ -389,11 +389,11 @@ class Git(LazyMixin):
if self.GIT_PYTHON_TRACE == 'full':
cmdstr = " ".join(command)
if stderr_value:
- print "%s -> %d; stdout: '%s'; stderr: '%s'" % (cmdstr, status, stdout_value, stderr_value)
+ print("%s -> %d; stdout: '%s'; stderr: '%s'" % (cmdstr, status, stdout_value, stderr_value))
elif stdout_value:
- print "%s -> %d; stdout: '%s'" % (cmdstr, status, stdout_value)
+ print("%s -> %d; stdout: '%s'" % (cmdstr, status, stdout_value))
else:
- print "%s -> %d" % (cmdstr, status)
+ print("%s -> %d" % (cmdstr, status))
# END handle debug printing
if with_exceptions and status != 0:
@@ -522,14 +522,16 @@ class Git(LazyMixin):
raise
# END handle overridden variable
type(self).GIT_PYTHON_GIT_EXECUTABLE = self.git_exec_name_win
- call = [self.GIT_PYTHON_GIT_EXECUTABLE] + list(args)
try:
return self.execute(make_call(), **_kwargs)
finally:
import warnings
- msg = "WARNING: Automatically switched to use git.cmd as git executable, which reduces performance by ~70%."
- msg += "Its recommended to put git.exe into the PATH or to set the %s environment variable to the executable's location" % self._git_exec_env_var
+ msg = "WARNING: Automatically switched to use git.cmd as git executable"
+ msg += ", which reduces performance by ~70%."
+ msg += "Its recommended to put git.exe into the PATH or to "
+ msg += "set the %s " % self._git_exec_env_var
+ msg += "environment variable to the executable's location"
warnings.warn(msg)
# END print of warning
# END catch first failure