1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-22 14:52:41 +01:00

Stop "git blame" from printing "^" markers on root repository commits

Summary: Depends on D19391. Ref T13126. See that task for some details on what's going on here.

Test Plan:
  - Viewed a file which includes lines that were added during the first commit to the repository.
  - Before D19391: fatal.
  - After D19391: blank.
  - After this patch: accurate blame information.

Reviewers: amckinley

Reviewed By: amckinley

Maniphest Tasks: T13126

Differential Revision: https://secure.phabricator.com/D19392
This commit is contained in:
epriestley 2018-04-20 13:09:47 -07:00
parent 95e179d9a4
commit 8c78cde32f

View file

@ -7,8 +7,12 @@ final class DiffusionGitBlameQuery extends DiffusionBlameQuery {
$commit = $request->getCommit();
// NOTE: The "--root" flag suppresses the addition of the "^" boundary
// commit marker. Without it, root commits render with a "^" before them,
// and one fewer character of the commit hash.
return $repository->getLocalCommandFuture(
'--no-pager blame -s -l %s -- %s',
'--no-pager blame --root -s -l %s -- %s',
$commit,
$path);
}