equal
deleted
inserted
replaced
740 destrepo.svfs.fncache.add(unencodedname) |
740 destrepo.svfs.fncache.add(unencodedname) |
741 if copydata: |
741 if copydata: |
742 destrepo.svfs.fncache.add(unencodedname[:-2] + b'.d') |
742 destrepo.svfs.fncache.add(unencodedname[:-2] + b'.d') |
743 |
743 |
744 |
744 |
745 UPGRADE_CHANGELOG = object() |
745 UPGRADE_CHANGELOG = b"changelog" |
746 UPGRADE_MANIFEST = object() |
746 UPGRADE_MANIFEST = b"manifest" |
747 UPGRADE_FILELOGS = object() |
747 UPGRADE_FILELOGS = b"all-filelogs" |
748 |
748 |
749 UPGRADE_ALL_REVLOGS = frozenset( |
749 UPGRADE_ALL_REVLOGS = frozenset( |
750 [UPGRADE_CHANGELOG, UPGRADE_MANIFEST, UPGRADE_FILELOGS] |
750 [UPGRADE_CHANGELOG, UPGRADE_MANIFEST, UPGRADE_FILELOGS] |
751 ) |
751 ) |
752 |
752 |
1337 |
1337 |
1338 def printupgradeactions(): |
1338 def printupgradeactions(): |
1339 for a in actions: |
1339 for a in actions: |
1340 ui.status(b'%s\n %s\n\n' % (a.name, a.upgrademessage)) |
1340 ui.status(b'%s\n %s\n\n' % (a.name, a.upgrademessage)) |
1341 |
1341 |
|
1342 def print_affected_revlogs(): |
|
1343 if not revlogs: |
|
1344 ui.write((b'no revlogs to process\n')) |
|
1345 else: |
|
1346 ui.write((b'processed revlogs:\n')) |
|
1347 for r in sorted(revlogs): |
|
1348 ui.write((b' - %s\n' % r)) |
|
1349 ui.write((b'\n')) |
|
1350 |
1342 if not run: |
1351 if not run: |
1343 fromconfig = [] |
1352 fromconfig = [] |
1344 onlydefault = [] |
1353 onlydefault = [] |
1345 |
1354 |
1346 for d in deficiencies: |
1355 for d in deficiencies: |
1388 ) |
1397 ) |
1389 |
1398 |
1390 printrequirements() |
1399 printrequirements() |
1391 printoptimisations() |
1400 printoptimisations() |
1392 printupgradeactions() |
1401 printupgradeactions() |
|
1402 print_affected_revlogs() |
1393 |
1403 |
1394 unusedoptimize = [i for i in alloptimizations if i not in actions] |
1404 unusedoptimize = [i for i in alloptimizations if i not in actions] |
1395 |
1405 |
1396 if unusedoptimize: |
1406 if unusedoptimize: |
1397 ui.status( |
1407 ui.status( |
1407 # Else we're in the run=true case. |
1417 # Else we're in the run=true case. |
1408 ui.write(_(b'upgrade will perform the following actions:\n\n')) |
1418 ui.write(_(b'upgrade will perform the following actions:\n\n')) |
1409 printrequirements() |
1419 printrequirements() |
1410 printoptimisations() |
1420 printoptimisations() |
1411 printupgradeactions() |
1421 printupgradeactions() |
|
1422 print_affected_revlogs() |
1412 |
1423 |
1413 upgradeactions = [a.name for a in actions] |
1424 upgradeactions = [a.name for a in actions] |
1414 |
1425 |
1415 ui.status(_(b'beginning upgrade...\n')) |
1426 ui.status(_(b'beginning upgrade...\n')) |
1416 with repo.wlock(), repo.lock(): |
1427 with repo.wlock(), repo.lock(): |