templater: allow piping generator-type function output to filters
Template functions use "yield"s assuming that the result will be combined
into a string, which means both "f -> str" and "f -> generator" should behave
in the same way.
Before this patch, piping generator function resulted in a cryptic error.
We had to insert "|stringify" in this case.
$ hg log --template '{if(author, author)|user}\n'
abort: template filter 'userfilter' is not compatible with keyword
'[(<function runsymbol at 0x
7f5af2e8d8c0>, 'author'),
(<function runsymbol at 0x
7f5af2e8d8c0>, 'author')]'
manifest: don't let find() look inside manifestdict
The find() method is currently implemented by looking inside the _lm
field of the manifest dict. Future manifests types (tree manifests)
may not have such a field, so add a method for getting to the data
instead.
largefiles: replace manifestdict.__contains__, don't extend class
We're soon going to add an alternative manifest class
(treemanifest). Rather than extending both those classes by
largesfiles versions, let's replace the method on the manifest
instances.
files: use ctx object to access dirstate
This allows the cmdutil method to not need to be passed the repo as well as the
ctx.
copies: added manifests to computenonoverlap
Commit
30219bd46ed7 changed the computenonoverlap api's to not require the
manifests. We actually need the manifests in the remotefilelog extension so
we can find the file nodes for the various files that change. Let's add it
back to the function signature with a note explaining why.
This doesn't affect any behavior.
record: move dorecord from record to cmdutil
Part of a serie of patches to move record from hgext to core
record: remove dependency on hg module in record
Part of a series of patches to move record from hgext to core