mq: comply with filtering when injecting fake tags (
issue3812)
mq was injecting fake tags whenever the revisions were accessible
to the filtering level.
This issue impacts hgweb since it's common to have "secret" mq
patches. As secret changesets are filtered by hgweb, the tags
computation could break.
commit: factor out post-commit cleanup into workingctx
This pulls some of the logic for the cleanup that needs to happen
after a commit has been made otu of localrepo.commit and into
workingctx. This is part of a larger refactoring effort that will
eventually allow us to perform some types of merges in-memory.
localrepo: use workingctx for validation in commit
This changes localrepo.commit to use the workingctx it creates form
the munged output of localrepo.status while running some precommit
validation. Specifically, it uses functions that were already present
on the workingctx. I believe this is a net readabilty improvement,
and that this makes these lines consistent with the refactoring in a
subsequent patch that pulls some of the validation logic into
workingctx so that it can be reused elsewhere.
localrepo: create context used for actual commit earlier
localrepo.commit creates a workingctx, calls self.status, does some
munging on the changes status returns, does some validation on those
changes, and then creates a new workingctx from the changes. This
moves the creation of the new workginctx ahead of some validation,
with the intention of refactoring some of that validation logic into
the workingctx, so that it can be reused elsewhere.
debugobsolete: improve command help
The behavior without argument was not documented.
import: don't rollback on failed import --exact (
issue3616)
The checkexact() helper function was calling repo.rollback() from inside
an open transaction. In addition to being insane, this is unnecessary
because import will release the transaction on an exception.
It turns out that this has been broken since the feature was first
introduced, first released in v1.0:
changeset: 4263:
47ba52121433
user: Brendan Cully <brendan@kublai.com>
date: Thu Mar 22 10:44:59 2007 -0700
files: mercurial/commands.py mercurial/patch.py
description:
Add import --exact.
When this option is set, import will apply the patch (which must
be generated by export) to the parents specified in the patch,
and check that the node produced by the patch matches the node
ID in the patch.