Use patch.patch() when checking for patch availability.
The test is closer to what we want to know. It also makes sense when you deal with patched versions of patch() as most people do under win32.
Fix find_in_path not including some file extension logic under win32.
Windows shell resolves utility path by combining PATH, the utility name and a set of file extensions from PATHEXT.
Refactor commands.serve to allow other commands to run as services.
This introduces a new function, cmdutil.service.
Do not automatically rename an atomicfile if a write to it has generated an exception.
dirstate: make parents() faster.
This allows localrepository.status() to avoid reading all but the
first 40 bytes of the dirstate in the common case of running "hg
status".
localrepository.status: only acquire wlock if actually needed.
This speeds up the common case of not needing to update the dirstate,
and avoids the need to reload and parse the dirstate "just in case".
util._matcher: speed up regexp matching.
In
4babaa52badf, Benoit made a change that substantially slows matching
when a big .hgignore file is in play, because it calls into the regexp
matching engine potentially hundreds of times per file to be matched.
I've partly rolled back his change, so that we only call into the matcher
once per file, but preserved the ability to report a meaningful error
message if there's a syntax error in the regexp.