Show More
@@ -73,12 +73,13 b' def diffordiffstat(ui, repo, diffopts, n' | |||||
73 | if relroot != '': |
|
73 | if relroot != '': | |
74 | # XXX relative roots currently don't work if the root is within a |
|
74 | # XXX relative roots currently don't work if the root is within a | |
75 | # subrepo |
|
75 | # subrepo | |
76 | uirelroot = match.uipath(relroot) |
|
76 | uipathfn = scmutil.getuipathfn(repo, legacyrelativevalue=True) | |
|
77 | uirelroot = uipathfn(pathfn(relroot)) | |||
77 | relroot += '/' |
|
78 | relroot += '/' | |
78 | for matchroot in match.files(): |
|
79 | for matchroot in match.files(): | |
79 | if not matchroot.startswith(relroot): |
|
80 | if not matchroot.startswith(relroot): | |
80 |
ui.warn(_('warning: %s not inside relative root %s\n') % |
|
81 | ui.warn(_('warning: %s not inside relative root %s\n') % | |
81 |
|
|
82 | (uipathfn(pathfn(matchroot)), uirelroot)) | |
82 |
|
83 | |||
83 | relrootmatch = scmutil.match(ctx2, pats=[relroot], default='path') |
|
84 | relrootmatch = scmutil.match(ctx2, pats=[relroot], default='path') | |
84 | match = matchmod.intersectmatchers(match, relrootmatch) |
|
85 | match = matchmod.intersectmatchers(match, relrootmatch) |
General Comments 0
You need to be logged in to leave comments.
Login now