comparison hgext/relink.py @ 13659:a73f38d8bbdb

merge with stable
author Martin Geisler <mg@lazybytes.net>
date Wed, 16 Mar 2011 16:07:06 +0100
parents 0e200e1801f4 6cc306093b99
children 77b09a7fc8fc
comparison
equal deleted inserted replaced
13656:0e200e1801f4 13659:a73f38d8bbdb
40 raise util.Abort(_('hardlinks are not supported on this system')) 40 raise util.Abort(_('hardlinks are not supported on this system'))
41 src = hg.repository( 41 src = hg.repository(
42 hg.remoteui(repo, opts), 42 hg.remoteui(repo, opts),
43 ui.expandpath(origin or 'default-relink', origin or 'default')) 43 ui.expandpath(origin or 'default-relink', origin or 'default'))
44 if not src.local(): 44 if not src.local():
45 raise util.Abort('must specify local origin repository') 45 raise util.Abort(_('must specify local origin repository'))
46 ui.status(_('relinking %s to %s\n') % (src.store.path, repo.store.path)) 46 ui.status(_('relinking %s to %s\n') % (src.store.path, repo.store.path))
47 if repo.root == src.root:
48 ui.status(_('there is nothing to relink\n'))
49 return
50
47 locallock = repo.lock() 51 locallock = repo.lock()
48 try: 52 try:
49 remotelock = src.lock() 53 remotelock = src.lock()
50 try: 54 try:
51 candidates = sorted(collect(src, ui)) 55 candidates = sorted(collect(src, ui))