]> khamidou — GitHub mirrors - arcanist.git/commit
Fix "arc:this" and "arc:amended" base rules after D4838
authorepriestley <git@epriestley.com>
Thu, 14 Feb 2013 21:57:34 +0000 (13:57 -0800)
committerepriestley <git@epriestley.com>
Thu, 14 Feb 2013 21:57:34 +0000 (13:57 -0800)
commit39704f1e49f3a2e3453c2ca9cf8f9069b78b2aa0
tree23491b348c9cd9fa6b9803c2d6babb0f8a4efa87
parent7803b7da27885fedec32231c8f20734677156fcc
Fix "arc:this" and "arc:amended" base rules after D4838

Summary:
After D4383, we escape the base commit when constructing a command like this:

  hg log --rev (base::. - base)

However, if the base commit is a revset like ".^", we now escape it and Mercurial looks for a commit named ".^" (a valid mercurial branch name) instead.

Fix this by returning nodes for these rules instead of revsets. The "arc:this" rule is automatically used in some operations, like "arc amend", so users can hit this during normal workflows, not just with weird `--base` rules.

Test Plan: Ran "arc amend" in a Mercurial repository, didn't fatal out.

Reviewers: DurhamGoode, sid0

Reviewed By: DurhamGoode

CC: tido, aran
Differential Revision: https://secure.phabricator.com/D4949
src/repository/api/ArcanistMercurialAPI.php