revrange: don't parse revset aliases as hash prefixes (
issue4553)
If a user has a revsetalias defined, it is their explicit wish for
this alias to be parsed as a revset and nothing else. Although the
case of the alias being short enough and only contain the letters a-f
is probably kind of rare, it may still happen.
subrepos: support adding files in git subrepos
This support includes correct matching, so includes,
excludes and patterns are all supported.
subrepo: return only the manifest keys from hgsubrepo.files()
This is in line with the other subrepo classes (i.e. only the filenames are
returned). Archive iterates over the manifest keys, and since subrepo archive()
uses this method, it does too now. This will allow largefiles to override its
manifest keys to present the largefiles instead of the standins. Once in place,
we shouldn't need the copy/paste overrides of archive and subrepo archive in
largefiles, that don't quite behave like the core methods they are overriding.
archive: change the default prefix to '' from None
All current callers supply some sort of prefix, so the issue was hidden. But if
no parameter was specified, a crash occurred in the write() closure when
concatenating 'prefix' and 'name'.
debugsetparent: document one common caveat specifically
After calling debugsetparent, it's quite common that status is
incorrect. The command's help text already says that it should be used
with care, but let's describe this caveat explicitly since it's
probably the most common one.
repair: setup hookargs when processing bundle2s
addchangegroup() modifies its behavior based on the transaction source.
This is incorrect for bundle2 repair files, causing rebases to abort when this
option is enabled.
This diff specifies the source type in the way recommended by comments in
bundle2.py and adds a test to ensure that rebases with the experimental option
work successfully.
amend: check for directory renames for both merge parents (
issue4516)
Before this change, amending a merge would lose the rename information for file
adding in the second parents and implicitly renamed into a new directory.
In case of the merge, we also look for directory rename data from the second
parent. This seems to fix the bug and does not show other issues from the test
suite.
largefiles: avoid infinite recursive call of openlfdirstate in overriderevert
When there isn't lfdirstate file in cases below, "openlfdirstate()"
call "scmutil.match()" indirectly to build lfdirstate up.
- subrepos disabling largefiles locally
- lfdirstate file is missed accidentally
This causes infinite recursive call of "openlfdirstate()" in
"overriderevert()" (introduced by
79c2c29c71ae), because
"openlfdirstate()" is invoked from the function overriding
"scmutil.match()" itself.
To avoid infinite recursive call of "openlfdirstate()" in
"overriderevert()" in such cases, this patch passes "create=False"
argument to "openlfdirstate()".
"create=False" forcibly makes "openlfdirstate()" avoid code path to
build lfdirstate up.