Show More
@@ -19,6 +19,31 b' def hideablerevs(repo):' | |||
|
19 | 19 | This is a standalone function to help extensions to wrap it.""" |
|
20 | 20 | return obsolete.getrevs(repo, 'obsolete') |
|
21 | 21 | |
|
22 | def _gethiddenblockers(repo): | |
|
23 | """Get revisions that will block hidden changesets from being filtered | |
|
24 | ||
|
25 | This is a standalone function to help extensions to wrap it.""" | |
|
26 | assert not repo.changelog.filteredrevs | |
|
27 | hideable = hideablerevs(repo) | |
|
28 | blockers = [] | |
|
29 | if hideable: | |
|
30 | cl = repo.changelog | |
|
31 | firsthideable = min(hideable) | |
|
32 | revs = cl.revs(start=firsthideable) | |
|
33 | tofilter = repo.revs( | |
|
34 | '(%ld) and children(%ld)', list(revs), list(hideable)) | |
|
35 | blockers = [r for r in tofilter if r not in hideable] | |
|
36 | for par in repo[None].parents(): | |
|
37 | blockers.append(par.rev()) | |
|
38 | for bm in repo._bookmarks.values(): | |
|
39 | blockers.append(repo[bm].rev()) | |
|
40 | tags = {} | |
|
41 | tagsmod.readlocaltags(repo.ui, repo, tags, {}) | |
|
42 | if tags: | |
|
43 | blockers.extend(repo[t[0]].rev() for t in tags.values()) | |
|
44 | blockers.extend(repo[t].rev() for t in tags) | |
|
45 | return blockers | |
|
46 | ||
|
22 | 47 | def computehidden(repo): |
|
23 | 48 | """compute the set of hidden revision to filter |
|
24 | 49 |
General Comments 0
You need to be logged in to leave comments.
Login now