equal
deleted
inserted
replaced
181 def reporelpath(repo): |
181 def reporelpath(repo): |
182 """return path to this (sub)repo as seen from outermost repo""" |
182 """return path to this (sub)repo as seen from outermost repo""" |
183 parent = repo |
183 parent = repo |
184 while hasattr(parent, '_subparent'): |
184 while hasattr(parent, '_subparent'): |
185 parent = parent._subparent |
185 parent = parent._subparent |
186 return repo.root[len(parent.root)+1:] |
186 p = parent.root.rstrip(os.sep) |
|
187 return repo.root[len(p) + 1:] |
187 |
188 |
188 def subrelpath(sub): |
189 def subrelpath(sub): |
189 """return path to this subrepo as seen from outermost repo""" |
190 """return path to this subrepo as seen from outermost repo""" |
190 if hasattr(sub, '_relpath'): |
191 if hasattr(sub, '_relpath'): |
191 return sub._relpath |
192 return sub._relpath |