Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 13960:190e5f2043d9
update: fix check for no rev when a date is given
The previous check caught a corner case in which rev
was pointing to 0.
author | Idan Kamara <idankk86@gmail.com> |
---|---|
date | Tue, 19 Apr 2011 14:56:46 +0300 |
parents | 1184bb274cb3 |
children | ac1c75a7c6b5 |
comparison
equal
deleted
inserted
replaced
13959:141f88ae5276 | 13960:190e5f2043d9 |
---|---|
4196 c = repo[None] | 4196 c = repo[None] |
4197 if c.modified() or c.added() or c.removed(): | 4197 if c.modified() or c.added() or c.removed(): |
4198 raise util.Abort(_("uncommitted local changes")) | 4198 raise util.Abort(_("uncommitted local changes")) |
4199 | 4199 |
4200 if date: | 4200 if date: |
4201 if rev: | 4201 if rev is not None: |
4202 raise util.Abort(_("you can't specify a revision and a date")) | 4202 raise util.Abort(_("you can't specify a revision and a date")) |
4203 rev = cmdutil.finddate(ui, repo, date) | 4203 rev = cmdutil.finddate(ui, repo, date) |
4204 | 4204 |
4205 if clean or check: | 4205 if clean or check: |
4206 ret = hg.clean(repo, rev) | 4206 ret = hg.clean(repo, rev) |