1526 self._repo, unfi.changelog.rev(n), n, maybe_filtered=False |
1526 self._repo, unfi.changelog.rev(n), n, maybe_filtered=False |
1527 ) |
1527 ) |
1528 for n in p |
1528 for n in p |
1529 ] |
1529 ] |
1530 |
1530 |
|
1531 def setparents(self, p1node, p2node=nullid): |
|
1532 dirstate = self._repo.dirstate |
|
1533 with dirstate.parentchange(): |
|
1534 copies = dirstate.setparents(p1node, p2node) |
|
1535 pctx = self._repo[p1node] |
|
1536 if copies: |
|
1537 # Adjust copy records, the dirstate cannot do it, it |
|
1538 # requires access to parents manifests. Preserve them |
|
1539 # only for entries added to first parent. |
|
1540 for f in copies: |
|
1541 if f not in pctx and copies[f] in pctx: |
|
1542 dirstate.copy(copies[f], f) |
|
1543 if p2node == nullid: |
|
1544 for f, s in sorted(dirstate.copies().items()): |
|
1545 if f not in pctx and s not in pctx: |
|
1546 dirstate.copy(None, f) |
|
1547 |
1531 def _fileinfo(self, path): |
1548 def _fileinfo(self, path): |
1532 # populate __dict__['_manifest'] as workingctx has no _manifestdelta |
1549 # populate __dict__['_manifest'] as workingctx has no _manifestdelta |
1533 self._manifest |
1550 self._manifest |
1534 return super(workingctx, self)._fileinfo(path) |
1551 return super(workingctx, self)._fileinfo(path) |
1535 |
1552 |