scmutil: allow access to filecache descriptor on class
To make it easier to patch the wrapped function, make it possible to access the
filecache descriptor directly on the class (rather than have to use
ClassObject.__dict__['attributename']). Returning `self` when the first
argument to `__get__` is `None` makes the descriptor behave the same way
`property` objects do.
changegroup: don't send empty subdirectory manifest groups
When grafting/rebasing, it is common for multiple changesets to make
the same change to a subdirectory. When writing the revlog for the
directory, the revlog code already takes care of not writing the entry
again. In
0c2a088ffcc5 (changegroup: prune subdirectory dirlogs too,
2016-02-12), I added the corresponding code in changegroup (not
sending entries the client already has), but I forgot to avoid sending
the entire changegroup if no nodes remained in the pruned
set. Although that's harmless besides the wasted network traffic, the
receiving side was checking for it (copied from the changegroup code
for handling files). This resulted in the client crashing with:
abort: received dir revlog group is empty
Fix by simply not emitting a changegroup for the directory if there
were no changes is it. This matches how files are handled.
chg: ignore SIGINT while waiting pager termination
Otherwise the terminal would be left with unclean state. This is what
fcc4b55876c3 does.
chg: reset signal handlers to default before waiting pager
Our signal handlers forward signals to the server process, but it will
disappear soon after hgc_close(). So we should unregister handlers before
hgc_close(). Otherwise chg would abort due to kill(perrpid, sig) failure.
The problem is spotted by SIGWINCH while waiting pager termination.
help: document that [subpaths] may rewrite relative paths
The subpaths substitution logic first attempts to match the absolute
repository path, then the relative subrepository path if that failed.
doc: describe detail about checkambig optional argument
This is followup for patches below, which add checkambig argument to
existing function.
-
731ced087a4b
-
76f1ea360c7e
-
ce2d81aafbae
-
a109bf7e0dc2
ui: provide official way to reset internal state per command
This will allow us to clear in-memory password storage per runcommand().
I've updated commandserver to call resetstate() of both ui and repo.ui because
they may have different states in theory.
revset: extract function that validates sort() arguments
This function will be used in _optimize() to get rid of noop sort() call while
validating its arguments.
revset: build dict of extra sort options before evaluating set
Prepares for extracting a function that only validates sort options.