Show More
@@ -4375,9 +4375,9 b' def phase(ui, repo, *revs, **opts):' | |||
|
4375 | 4375 | lock = repo.lock() |
|
4376 | 4376 | try: |
|
4377 | 4377 | # set phase |
|
4378 | nodes = [ctx.node() for ctx in repo.set('%ld', revs)] | |
|
4379 | if not nodes: | |
|
4378 | if not revs: | |
|
4380 | 4379 | raise util.Abort(_('empty revision set')) |
|
4380 | nodes = [repo[r].node() for r in revs] | |
|
4381 | 4381 | olddata = repo._phasecache.getphaserevs(repo)[:] |
|
4382 | 4382 | phases.advanceboundary(repo, targetphase, nodes) |
|
4383 | 4383 | if opts['force']: |
@@ -101,6 +101,7 b' Note: old client behave as publish serve' | |||
|
101 | 101 | import errno |
|
102 | 102 | from node import nullid, nullrev, bin, hex, short |
|
103 | 103 | from i18n import _ |
|
104 | import util | |
|
104 | 105 | |
|
105 | 106 | allphases = public, draft, secret = range(3) |
|
106 | 107 | trackedphases = allphases[1:] |
@@ -250,6 +251,8 b' class phasecache(object):' | |||
|
250 | 251 | newroots = [n for n in nodes |
|
251 | 252 | if self.phase(repo, repo[n].rev()) < targetphase] |
|
252 | 253 | if newroots: |
|
254 | if nullid in newroots: | |
|
255 | raise util.Abort(_('cannot change null revision phase')) | |
|
253 | 256 | currentroots = currentroots.copy() |
|
254 | 257 | currentroots.update(newroots) |
|
255 | 258 | ctxs = repo.set('roots(%ln::)', currentroots) |
General Comments 0
You need to be logged in to leave comments.
Login now