Show More
@@ -4226,17 +4226,20 b' def phase(ui, repo, *revs, **opts):' | |||||
4226 | if not revs: |
|
4226 | if not revs: | |
4227 | raise util.Abort(_('no revisions specified')) |
|
4227 | raise util.Abort(_('no revisions specified')) | |
4228 |
|
4228 | |||
|
4229 | revs = scmutil.revrange(repo, revs) | |||
|
4230 | ||||
4229 | lock = None |
|
4231 | lock = None | |
4230 | ret = 0 |
|
4232 | ret = 0 | |
4231 | if targetphase is None: |
|
4233 | if targetphase is None: | |
4232 | # display |
|
4234 | # display | |
4233 |
for |
|
4235 | for r in revs: | |
|
4236 | ctx = repo[r] | |||
4234 | ui.write('%i: %s\n' % (ctx.rev(), ctx.phasestr())) |
|
4237 | ui.write('%i: %s\n' % (ctx.rev(), ctx.phasestr())) | |
4235 | else: |
|
4238 | else: | |
4236 | lock = repo.lock() |
|
4239 | lock = repo.lock() | |
4237 | try: |
|
4240 | try: | |
4238 | # set phase |
|
4241 | # set phase | |
4239 |
nodes = [ctx.node() for ctx in repo.set('%l |
|
4242 | nodes = [ctx.node() for ctx in repo.set('%ld', revs)] | |
4240 | if not nodes: |
|
4243 | if not nodes: | |
4241 | raise util.Abort(_('empty revision set')) |
|
4244 | raise util.Abort(_('empty revision set')) | |
4242 | olddata = repo._phaserev[:] |
|
4245 | olddata = repo._phaserev[:] |
General Comments 0
You need to be logged in to leave comments.
Login now