Mercurial > hg
changeset 44512:febe88a6f7f7
nodemap: use data from the index in debugnodemap --dump-new
It is better to run the actual code when generating a new nodemap cache from
scratch. So we do.
Differential Revision: https://phab.mercurial-scm.org/D8163
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Tue, 18 Feb 2020 18:32:55 +0100 |
parents | cadcc8c20860 |
children | e7fff9c3cdac |
files | mercurial/debugcommands.py |
diffstat | 1 files changed, 4 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/debugcommands.py Wed Feb 12 10:53:24 2020 +0100 +++ b/mercurial/debugcommands.py Tue Feb 18 18:32:55 2020 +0100 @@ -2109,7 +2109,10 @@ if opts['dump_new']: unfi = repo.unfiltered() cl = unfi.changelog - data = nodemap.persistent_data(cl.index) + if util.safehasattr(cl.index, "nodemap_data_all"): + data = cl.index.nodemap_data_all() + else: + data = nodemap.persistent_data(cl.index) ui.write(data) elif opts['dump_disk']: unfi = repo.unfiltered()