comparison mercurial/commands.py @ 6350:6aa4a3fa4e60

update: no -C needed to switch branches without outstanding changes
author Matt Mackall <mpm@selenic.com>
date Sat, 22 Mar 2008 13:30:08 -0500
parents 3b42f7ac6916
children 04d615b2d5e9
comparison
equal deleted inserted replaced
6349:6aaf5b1d8f15 6350:6aa4a3fa4e60
2748 2748
2749 Update the working directory to the specified revision, or the 2749 Update the working directory to the specified revision, or the
2750 tip of the current branch if none is specified. 2750 tip of the current branch if none is specified.
2751 See 'hg help dates' for a list of formats valid for -d/--date. 2751 See 'hg help dates' for a list of formats valid for -d/--date.
2752 2752
2753 If there are no outstanding changes in the working directory and 2753 If there are no outstanding changes in the working directory, the
2754 there is a linear relationship between the current version and the 2754 result is the requested version.
2755 requested version, the result is the requested version. 2755
2756 2756 If the requested version is a descendant of the working directory
2757 To merge the working directory with another revision, use the 2757 and there are outstanding changes, those changes will be merged
2758 merge command. 2758 into the result.
2759 2759
2760 By default, update will refuse to run if doing so would require 2760 By default, update will refuse to run if there are outstanding
2761 discarding local changes. 2761 changes and the update spans branches.
2762 """ 2762 """
2763 if rev and node: 2763 if rev and node:
2764 raise util.Abort(_("please specify just one revision")) 2764 raise util.Abort(_("please specify just one revision"))
2765 2765
2766 if not rev: 2766 if not rev: