Changeset - 9d27481228a1
[Not reviewed]
beta
0 1 0
Marcin Kuzminski - 14 years ago 2012-04-11 23:10:46
marcin@python-works.com
Extend GIT command wrapper with GIT_CONFIG_NOGLOBAL=1 to bypass gitconfig global
1 file changed with 3 insertions and 2 deletions:
0 comments (0 inline, 0 general)
rhodecode/lib/vcs/backends/git/repository.py
Show inline comments
 
@@ -78,11 +78,12 @@ class GitRepository(BaseRepository):
 

	
 
        :param cmd: git command to be executed
 
        """
 

	
 
        #cmd = '(cd %s && git %s)' % (self.path, cmd)
 
        if isinstance(cmd, basestring):
 
            cmd = 'git %s' % cmd
 
            cmd = 'GIT_CONFIG_NOGLOBAL=1 git %s' % cmd
 
        else:
 
            cmd = ['git'] + cmd
 
            cmd = ['GIT_CONFIG_NOGLOBAL=1', 'git'] + cmd
 
        try:
 
            opts = dict(
 
                shell=isinstance(cmd, basestring),
0 comments (0 inline, 0 general)