equal
deleted
inserted
replaced
200 def reporelpath(repo): |
200 def reporelpath(repo): |
201 """return path to this (sub)repo as seen from outermost repo""" |
201 """return path to this (sub)repo as seen from outermost repo""" |
202 parent = repo |
202 parent = repo |
203 while util.safehasattr(parent, '_subparent'): |
203 while util.safehasattr(parent, '_subparent'): |
204 parent = parent._subparent |
204 parent = parent._subparent |
205 return repo.root[len(parent.root)+1:] |
205 p = parent.root.rstrip(os.sep) |
|
206 return repo.root[len(p) + 1:] |
206 |
207 |
207 def subrelpath(sub): |
208 def subrelpath(sub): |
208 """return path to this subrepo as seen from outermost repo""" |
209 """return path to this subrepo as seen from outermost repo""" |
209 if util.safehasattr(sub, '_relpath'): |
210 if util.safehasattr(sub, '_relpath'): |
210 return sub._relpath |
211 return sub._relpath |