diff --git a/git_cl.py b/git_cl.py index aa19d29cb..a186029f1 100755 --- a/git_cl.py +++ b/git_cl.py @@ -278,7 +278,7 @@ class Settings(object): if self.is_git_svn is None: # If you have any "svn-remote.*" config keys, we think you're using svn. self.is_git_svn = RunGitWithCode( - ['config', '--get-regexp', r'^svn-remote\.'])[0] == 0 + ['config', '--local', '--get-regexp', r'^svn-remote\.'])[0] == 0 return self.is_git_svn def GetSVNBranch(self): diff --git a/tests/git_cl_test.py b/tests/git_cl_test.py index 58508bf45..a890dac4f 100755 --- a/tests/git_cl_test.py +++ b/tests/git_cl_test.py @@ -171,7 +171,7 @@ class TestGitCl(TestCase): return [ ((['git', 'config', 'rietveld.cc'],), ''), ((['git', 'config', 'branch.master.base-url'],), ''), - ((['git', 'config', '--get-regexp', '^svn-remote\\.'],), + ((['git', 'config', '--local', '--get-regexp', '^svn-remote\\.'],), (('', None), 0)), ((['git', 'rev-parse', '--show-cdup'],), ''), ((['git', 'svn', 'info'],), ''), @@ -206,7 +206,7 @@ class TestGitCl(TestCase): @classmethod def _dcommit_calls_1(cls): return [ - ((['git', 'config', '--get-regexp', '^svn-remote\\.'],), + ((['git', 'config', '--local', '--get-regexp', '^svn-remote\\.'],), ((('svn-remote.svn.url svn://svn.chromium.org/chrome\n' 'svn-remote.svn.fetch trunk/src:refs/remotes/origin/master'), None),