comparison mercurial/hg.py @ 9714:2f1ab7f77ddc

clone: add option -u/--updaterev
author Adrian Buehlmann <adrian@cadifra.com>
date Thu, 05 Nov 2009 11:05:13 +0100
parents a3d73b3e1f8a
children 75520c24feda
comparison
equal deleted inserted replaced
9713:d193cc97c4e8 9714:2f1ab7f77ddc
307 dest_repo.ui.setconfig('paths', 'default', abspath) 307 dest_repo.ui.setconfig('paths', 'default', abspath)
308 308
309 if update: 309 if update:
310 if update is not True: 310 if update is not True:
311 checkout = update 311 checkout = update
312 if src_repo.local():
313 checkout = src_repo.lookup(update)
312 for test in (checkout, 'default', 'tip'): 314 for test in (checkout, 'default', 'tip'):
313 if test is None: 315 if test is None:
314 continue 316 continue
315 try: 317 try:
316 uprev = dest_repo.lookup(test) 318 uprev = dest_repo.lookup(test)