1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-11-10 17:02:40 +01:00
phorge-arcanist/src
epriestley 4e888458d7 In "arc patch", use "cat-file -t" instead of "rev-parse --verify" to check for commits.
Summary:
  - `git rev-parse --verify` "verifies" very valid-looking commit name, not just valid commit names.
  - Currently, if we can't find the base rev we'll incorrectly "verify" it and then fail on "git checkout -b <branch> <some bogus commit>".
  - Instead, use `git cat-file -t`.
  - See similar fix in D1590.

Example:

  $ git rev-parse --verify aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
  aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

Test Plan: Ran "arc patch" in a mismatched local, hit "Y" to branch, got a branch off HEAD instead of an error.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran, epriestley

Differential Revision: https://secure.phabricator.com/D1947
2012-03-19 19:11:52 -07:00
..
branch Use execxLocal() for ArcanistGitAPI 2012-03-02 16:47:34 -08:00
configuration Add an "arc alias" command 2012-02-21 13:16:52 -08:00
difference Add a test case to make sure prefix/suffix intraline diffs work correctly 2012-03-12 18:21:44 -07:00
differential Remove chooseRevision() and DifferentialRevisionRef 2012-03-09 08:57:24 -08:00
docs Reorganize documentation. 2011-05-31 12:14:20 -07:00
events/constant/type Allow modification of the svn commit message via an event listener 2011-11-16 16:40:19 -08:00
exception Finalize Arcanist Classes 2012-01-31 12:07:05 -08:00
lint Raise a lint error when code uses a PHP 5.3 feature in Phabricator 2012-03-09 13:51:02 -08:00
parser Fix an issue with unified patch generation for terminal newline changes 2012-03-16 13:40:11 -07:00
repository Don't fatal without Conduit for "--patch" and "--bundle" 2012-03-16 13:40:33 -07:00
unit Don't show "not executable" for files with no coverage information 2012-03-12 17:04:51 -07:00
workflow In "arc patch", use "cat-file -t" instead of "rev-parse --verify" to check for commits. 2012-03-19 19:11:52 -07:00
workingcopyidentity Finalize Arcanist Classes 2012-01-31 12:07:05 -08:00
__phutil_library_init__.php Initial commit. 2011-01-09 15:22:25 -08:00
__phutil_library_map__.php Remove chooseRevision() and DifferentialRevisionRef 2012-03-09 08:57:24 -08:00