graft: move `if continue` to elif and add new line
This will make upcoming patch where we introduce a new elif for the abort case
more readable. Also added a new line before the if-else starts.
Differential Revision: https://phab.mercurial-scm.org/D3752
graft: start storing new nodes formed in graftstate
This patch starts storing the new nodes formed during the ongoing graft
operation in the graftstate. We need the list of new nodes formed while
implmenting `graft --abort` which will strip out the new nodes.
Differential Revision: https://phab.mercurial-scm.org/D3751
show: use filter() function to strip "tip" tag
Before, an empty tag "" was inserted in place of "tip", resulting in double
spaces.
templater: extend filter() to accept template expression for emptiness test
This utilizes the pass-by-name nature of template arguments.
templater: introduce filter() function to remove empty items from list
The primary use case is to filter out "tip" from a list of tags.
templater: fix truth testing of integer 0 taken from a list/dict
Broken at
f9c426385853. bool(python_value) shouldn't be used here since
an integer 0 has to be truthy for backward compatibility.
formatter: look for template symbols from the associated name
Otherwise symbolsused() would fail if a named template is specified with -T.
py3: add b'' prefixes in tests/test-obsolete-divergent.t
This makes the test pass on Python 3.
# skip-blame because just b'' prefixes.
Differential Revision: https://phab.mercurial-scm.org/D3832