Commit b69edf15 authored by Reinout van Rees's avatar Reinout van Rees

Merge commit 'ff5cffeb' into reinout-relative-test

parents 259bc974 ff5cffeb
......@@ -1152,6 +1152,8 @@ def _relative_path(common, path):
def _relativitize(path, script, relative_paths):
if path == script:
raise AssertionError("path == script")
if path == relative_paths:
return "base"
common = os.path.dirname(os.path.commonprefix([path, script]))
if (common == relative_paths or
common.startswith(os.path.join(relative_paths, ''))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment