bundlerepo: unify common code into a new getremotechanges
The pattern where we fetch incoming remote changes and return
them as a local bundlerepo seems common. It's nicer to have this
code unified.
keyword: only use expensive fctx.cmp when needed
Restrict expensive cmp to cases when:
- comparing against working directory
and
- encode filters active
or
- path is configured for keyword expansion
context: narrow down filter special case in filectx.cmp()
cmp via filelog when encode filters are present, but only when
actually comparing to the working directory.
incoming: rename variable
Groundwork so that incoming and graphlog.incoming code look the same and get
easier to unify.
import: only the first hg patch marker should be processed (
issue2417)
Proper use of the hgpatch state variable had been lost in the final edits of
d7452292f9d3 - now it works more like intended.