diff options
author | W. Trevor King <wking@drexel.edu> | 2008-11-13 15:27:07 -0500 |
---|---|---|
committer | W. Trevor King <wking@drexel.edu> | 2008-11-13 15:27:07 -0500 |
commit | f6253f4c6ba301954a5b9beed4e5b41e74bb8004 (patch) | |
tree | ac89bd6bfead338a7cd3c7e6edc1326a34520157 /libbe/git.py | |
parent | 49f81fa291ca925ec985dc52f51b9a37bb3106ee (diff) | |
download | bugseverywhere-f6253f4c6ba301954a5b9beed4e5b41e74bb8004.tar.gz |
Oops... *Now* I've fixed 0cad
Diffstat (limited to 'libbe/git.py')
-rw-r--r-- | libbe/git.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libbe/git.py b/libbe/git.py index 5c377fd..172c324 100644 --- a/libbe/git.py +++ b/libbe/git.py @@ -22,7 +22,11 @@ def strip_git(filename): # Find the base path of the GIT tree, in order to strip that leading # path from arguments to git -- it doesn't like absolute paths. if os.path.isabs(filename): - filename = filename[len(git_repo_for_path('.'))+1:] + absRepoDir = os.path.abspath(git_repo_for_path('.')) + absRepoSlashedDir = os.path.join(absRepoDir,"") + assert filename.startswith(absRepoSlashedDir), \ + "file %s not in git repo %s" % (filename, absRepoSlashedDir) + filename = filename.lstrip(absRepoSlashedDir) return filename def invoke_client(*args, **kwargs): |