summaryrefslogtreecommitdiffstats
path: root/scripts/git
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/git')
-rwxr-xr-xscripts/git9
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/git b/scripts/git
index 8adf5c9ecb..644055e540 100755
--- a/scripts/git
+++ b/scripts/git
@@ -10,7 +10,14 @@ os.environ['PSEUDO_UNLOAD'] = '1'
10 10
11# calculate path to the real 'git' 11# calculate path to the real 'git'
12path = os.environ['PATH'] 12path = os.environ['PATH']
13path = path.replace(os.path.dirname(sys.argv[0]), '') 13# we need to remove our path but also any other copy of this script which
14# may be present, e.g. eSDK.
15replacements = [os.path.dirname(sys.argv[0])]
16for p in path.split(":"):
17 if p.endswith("/scripts"):
18 replacements.append(p)
19for r in replacements:
20 path = path.replace(r, '/ignoreme')
14real_git = shutil.which('git', path=path) 21real_git = shutil.which('git', path=path)
15 22
16if len(sys.argv) == 1: 23if len(sys.argv) == 1: