Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 232:fc4a6e5b5812
hg resolve: merge a given node into the working directory
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
hg resolve: merge a given node into the working directory
This is the first pass at working directory-based merges. Doing a
resolve adds a second parent to the working directory state for the
next commit.
manifest hash: 827b19995dd2d7686286da3b62c7d5fe3e0bc48c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCoMSHywK+sNU5EO8RAnOkAJsHH9jviMJcQJ4JurFuSlrbIwKqRACdHgNC
kkfoAxX2E5jkuOeSJ1Hjalk=
=bdrT
-----END PGP SIGNATURE-----
author | mpm@selenic.com |
---|---|
date | Fri, 03 Jun 2005 12:58:47 -0800 |
parents | 00ea3613f82c |
children | 4f802588cdfb 4f802588cdfb afe895fcc0d0 |
comparison
equal
deleted
inserted
replaced
231:15e7c6cee929 | 232:fc4a6e5b5812 |
---|---|
151 | 151 |
152 for n in p: | 152 for n in p: |
153 if n != hg.nullid: | 153 if n != hg.nullid: |
154 ui.write("%d:%s\n" % (repo.changelog.rev(n), hg.hex(n))) | 154 ui.write("%d:%s\n" % (repo.changelog.rev(n), hg.hex(n))) |
155 | 155 |
156 def resolve(ui, repo, node = None): | |
157 '''merge a given node or the current tip into the working dir''' | |
158 if not node: | |
159 node = repo.changelog.tip() | |
160 else: | |
161 node = repo.lookup(node) | |
162 repo.resolve(node) | |
163 | |
156 def status(ui, repo): | 164 def status(ui, repo): |
157 '''show changed files in the working directory | 165 '''show changed files in the working directory |
158 | 166 |
159 C = changed | 167 C = changed |
160 A = added | 168 A = added |
182 ('u', 'user', None, 'show user'), | 190 ('u', 'user', None, 'show user'), |
183 ('n', 'number', None, 'show revision number'), | 191 ('n', 'number', None, 'show revision number'), |
184 ('c', 'changeset', None, 'show changeset')], | 192 ('c', 'changeset', None, 'show changeset')], |
185 'hg annotate [-u] [-c] [-n] [-r id] [files]'), | 193 'hg annotate [-u] [-c] [-n] [-r id] [files]'), |
186 "parents": (parents, [], 'hg parents [node]'), | 194 "parents": (parents, [], 'hg parents [node]'), |
195 "resolve": (resolve, [], 'hg resolve [node]'), | |
187 "status": (status, [], 'hg status'), | 196 "status": (status, [], 'hg status'), |
188 "undo": (undo, [], 'hg undo'), | 197 "undo": (undo, [], 'hg undo'), |
189 } | 198 } |
190 | 199 |
191 norepo = "init branch help" | 200 norepo = "init branch help" |