##// END OF EJS Templates
largefiles: fix check that ensures that --all-largefiles is only used locally...
Manuel Jacob -
r52691:187d7c85 stable
parent child Browse files
Show More
@@ -46,6 +46,8 b' from mercurial.upgrade_utils import ('
46 actions as upgrade_actions,
46 actions as upgrade_actions,
47 )
47 )
48
48
49 from mercurial.utils import urlutil
50
49 from . import (
51 from . import (
50 lfcommands,
52 lfcommands,
51 lfutil,
53 lfutil,
@@ -1136,7 +1138,10 b' def overrideclone(orig, ui, source, dest'
1136 d = dest
1138 d = dest
1137 if d is None:
1139 if d is None:
1138 d = hg.defaultdest(source)
1140 d = hg.defaultdest(source)
1139 if opts.get('all_largefiles') and not hg.islocal(d):
1141 if opts.get('all_largefiles') and urlutil.url(d).scheme not in (
1142 b'file',
1143 None,
1144 ):
1140 raise error.Abort(
1145 raise error.Abort(
1141 _(b'--all-largefiles is incompatible with non-local destination %s')
1146 _(b'--all-largefiles is incompatible with non-local destination %s')
1142 % d
1147 % d
@@ -1076,6 +1076,11 b' Ensure base clone command argument valid'
1076 abort: --all-largefiles is incompatible with non-local destination ssh://localhost/a
1076 abort: --all-largefiles is incompatible with non-local destination ssh://localhost/a
1077 [255]
1077 [255]
1078
1078
1079 $ touch existing_destination
1080 $ hg clone --all-largefiles a existing_destination
1081 abort: destination 'existing_destination' already exists
1082 [10]
1083
1079 Test pulling with --all-largefiles flag. Also test that the largefiles are
1084 Test pulling with --all-largefiles flag. Also test that the largefiles are
1080 downloaded from 'default' instead of 'default-push' when no source is specified
1085 downloaded from 'default' instead of 'default-push' when no source is specified
1081 (issue3584)
1086 (issue3584)
General Comments 0
You need to be logged in to leave comments. Login now