Mercurial > hg-stable
changeset 20083:c69e5911888d
relink: abort earlier when on different devices (issue3916)
Add a first check of the devices before collecting candidate files. This is
much quicker when big repos are on different devices.
Keep the existing check in prune. It checks for same device of the files. This
could probably be different in a special repo store (with symlinks).
author | Simon Heimberg <simohe@besonet.ch> |
---|---|
date | Sat, 09 Nov 2013 14:50:58 +0100 |
parents | b04cc8651a63 |
children | a3378a1b0a05 |
files | hgext/relink.py |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/relink.py Mon Nov 11 22:59:26 2013 +0100 +++ b/hgext/relink.py Sat Nov 09 14:50:58 2013 +0100 @@ -48,6 +48,10 @@ ui.status(_('there is nothing to relink\n')) return + if not util.samedevice(src.store.path, repo.store.path): + # No point in continuing + raise util.Abort(_('source and destination are on different devices')) + locallock = repo.lock() try: remotelock = src.lock()