Why is hg identify so slow?

Patrick Mézard pmezard at gmail.com
Wed Jun 25 07:11:28 CDT 2008

Frank Kingswood a écrit :
> Patrick Mézard wrote:
>> Frank Kingswood a écrit :
>>> Hallo!
>>> I've noticed several times in the past that hg identify is quite slow
>>> compared to hg status. It would seem to me that hg identify actually
>>> has slightly less to do - no need to print out modified or unknown
>>> files.
>> Actually it does append a small "+" if you have local changes.
> No, it doesn't work like status:
> $ hg id
> abcf05896578 tip
> $ touch new-file
> $ hg id
> abcf05896578 tip
> $ hg st
> ? new-file

Right, that's because we are using a workingctx() to simplify the code. We could be smart and write the code directly with proper arguments to status(). I guess nobody cared enough about identify performance until now.

Patrick Mézard

More information about the Mercurial-devel mailing list