Mercurial > hg
comparison mercurial/copies.py @ 40448:873f3682c8af stable
narrow: make copies.pathcopies() filter with narrowspec again
I broke this in 707c3804e607 (narrow: move copies overrides to core,
2018-09-28).
Differential Revision: https://phab.mercurial-scm.org/D5203
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Thu, 01 Nov 2018 13:20:12 -0700 |
parents | 2e9378f62232 |
children | 07a66c1387d1 |
comparison
equal
deleted
inserted
replaced
40447:f1c1b4d0e695 | 40448:873f3682c8af |
---|---|
217 return cm | 217 return cm |
218 | 218 |
219 def _forwardcopies(a, b, match=None): | 219 def _forwardcopies(a, b, match=None): |
220 """find {dst@b: src@a} copy mapping where a is an ancestor of b""" | 220 """find {dst@b: src@a} copy mapping where a is an ancestor of b""" |
221 | 221 |
222 match = a.repo().narrowmatch(match) | |
222 # check for working copy | 223 # check for working copy |
223 if b.rev() is None: | 224 if b.rev() is None: |
224 if a == b.p1(): | 225 if a == b.p1(): |
225 # short-circuit to avoid issues with merge states | 226 # short-circuit to avoid issues with merge states |
226 return _dirstatecopies(b, match) | 227 return _dirstatecopies(b, match) |