equal
deleted
inserted
replaced
1487 |
1487 |
1488 if not len(cache): |
1488 if not len(cache): |
1489 ui.write(_('cache empty\n')) |
1489 ui.write(_('cache empty\n')) |
1490 else: |
1490 else: |
1491 ui.write( |
1491 ui.write( |
1492 _('Cache contains %d manifest entries, in order of most to ' |
1492 _('cache contains %d manifest entries, in order of most to ' |
1493 'least recent:\n') % (len(cache),)) |
1493 'least recent:\n') % (len(cache),)) |
1494 totalsize = 0 |
1494 totalsize = 0 |
1495 for nodeid in cache: |
1495 for nodeid in cache: |
1496 # Use cache.get to not update the LRU order |
1496 # Use cache.get to not update the LRU order |
1497 data = cache.get(nodeid) |
1497 data = cache.get(nodeid) |
1499 totalsize += size + 24 # 20 bytes nodeid, 4 bytes size |
1499 totalsize += size + 24 # 20 bytes nodeid, 4 bytes size |
1500 ui.write(_('id: %s, size %s\n') % ( |
1500 ui.write(_('id: %s, size %s\n') % ( |
1501 hex(nodeid), util.bytecount(size))) |
1501 hex(nodeid), util.bytecount(size))) |
1502 ondisk = cache._opener.stat('manifestfulltextcache').st_size |
1502 ondisk = cache._opener.stat('manifestfulltextcache').st_size |
1503 ui.write( |
1503 ui.write( |
1504 _('Total cache data size %s, on-disk %s\n') % ( |
1504 _('total cache data size %s, on-disk %s\n') % ( |
1505 util.bytecount(totalsize), util.bytecount(ondisk)) |
1505 util.bytecount(totalsize), util.bytecount(ondisk)) |
1506 ) |
1506 ) |
1507 |
1507 |
1508 @command('debugmergestate', [], '') |
1508 @command('debugmergestate', [], '') |
1509 def debugmergestate(ui, repo, *args): |
1509 def debugmergestate(ui, repo, *args): |