Show More
@@ -1084,6 +1084,11 b' coreconfigitem(' | |||||
1084 | ) |
|
1084 | ) | |
1085 | coreconfigitem( |
|
1085 | coreconfigitem( | |
1086 | b'experimental', |
|
1086 | b'experimental', | |
|
1087 | b'sharesafe-warn-outdated-shares', | |||
|
1088 | default=True, | |||
|
1089 | ) | |||
|
1090 | coreconfigitem( | |||
|
1091 | b'experimental', | |||
1087 | b'single-head-per-branch', |
|
1092 | b'single-head-per-branch', | |
1088 | default=False, |
|
1093 | default=False, | |
1089 | ) |
|
1094 | ) |
@@ -607,7 +607,9 b' def makelocalrepository(baseui, path, in' | |||||
607 | storevfs, |
|
607 | storevfs, | |
608 | requirements, |
|
608 | requirements, | |
609 | ) |
|
609 | ) | |
610 | else: |
|
610 | elif ui.configbool( | |
|
611 | b'experimental', b'sharesafe-warn-outdated-shares' | |||
|
612 | ): | |||
611 | ui.warn( |
|
613 | ui.warn( | |
612 | _( |
|
614 | _( | |
613 | b'warning: source repository supports share-safe functionality.' |
|
615 | b'warning: source repository supports share-safe functionality.' |
@@ -257,10 +257,11 b' def upgrade_share_to_safe(ui, hgvfs, sto' | |||||
257 | current_requirements.add(requirementsmod.SHARESAFE_REQUIREMENT) |
|
257 | current_requirements.add(requirementsmod.SHARESAFE_REQUIREMENT) | |
258 | ui.warn(_(b'repository upgraded to use share-safe mode\n')) |
|
258 | ui.warn(_(b'repository upgraded to use share-safe mode\n')) | |
259 | except error.LockError as e: |
|
259 | except error.LockError as e: | |
260 | ui.warn( |
|
260 | if ui.configbool(b'experimental', b'sharesafe-warn-outdated-shares'): | |
261 | _(b'failed to upgrade share, got error: %s\n') |
|
261 | ui.warn( | |
262 | % stringutil.forcebytestr(e.strerror) |
|
262 | _(b'failed to upgrade share, got error: %s\n') | |
263 | ) |
|
263 | % stringutil.forcebytestr(e.strerror) | |
|
264 | ) | |||
264 | finally: |
|
265 | finally: | |
265 | if wlock: |
|
266 | if wlock: | |
266 | wlock.release() |
|
267 | wlock.release() |
@@ -392,6 +392,12 b' Upgrade' | |||||
392 |
|
392 | |||
393 | Make sure existing shares still works |
|
393 | Make sure existing shares still works | |
394 |
|
394 | |||
|
395 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share --config experimental.sharesafe-warn-outdated-shares=false | |||
|
396 | @ f63db81e6dde1d9c78814167f77fb1fb49283f4f: added bar | |||
|
397 | | | |||
|
398 | o f3ba8b99bb6f897c87bbc1c07b75c6ddf43a4f77: added foo | |||
|
399 | ||||
|
400 | ||||
395 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share |
|
401 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share | |
396 | warning: source repository supports share-safe functionality. Reshare to upgrade. |
|
402 | warning: source repository supports share-safe functionality. Reshare to upgrade. | |
397 | @ f63db81e6dde1d9c78814167f77fb1fb49283f4f: added bar |
|
403 | @ f63db81e6dde1d9c78814167f77fb1fb49283f4f: added bar | |
@@ -544,6 +550,13 b' Check that if lock is taken, upgrade fai' | |||||
544 | | |
|
550 | | | |
545 | o f3ba8b99bb6f897c87bbc1c07b75c6ddf43a4f77: added foo |
|
551 | o f3ba8b99bb6f897c87bbc1c07b75c6ddf43a4f77: added foo | |
546 |
|
552 | |||
|
553 | ||||
|
554 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share --config experimental.sharesafe-auto-upgrade-shares=true --config experimental.sharesafe-warn-outdated-shares=false | |||
|
555 | @ f63db81e6dde1d9c78814167f77fb1fb49283f4f: added bar | |||
|
556 | | | |||
|
557 | o f3ba8b99bb6f897c87bbc1c07b75c6ddf43a4f77: added foo | |||
|
558 | ||||
|
559 | ||||
547 | $ rm ../nss-share/.hg/wlock |
|
560 | $ rm ../nss-share/.hg/wlock | |
548 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share --config experimental.sharesafe-auto-upgrade-shares=true |
|
561 | $ hg log -GT "{node}: {desc}\n" -R ../nss-share --config experimental.sharesafe-auto-upgrade-shares=true | |
549 | repository upgraded to use share-safe mode |
|
562 | repository upgraded to use share-safe mode |
General Comments 0
You need to be logged in to leave comments.
Login now