Parse and display commit authorship date in Git in Diffusion
Summary: Fixes T8826. Git tracks an "author date", which may be different from the "committed date". We don't currently extract/show this; do so.
Test Plan: {F1059235}
Reviewers: chad
Reviewed By: chad
Maniphest Tasks: T8826
Differential Revision: https://secure.phabricator.com/D14995
This commit is contained in:
@@ -492,8 +492,12 @@ final class DiffusionCommitController extends DiffusionController {
|
||||
|
||||
if (!$repository->isSVN()) {
|
||||
$authored_info = id(new PHUIStatusItemView());
|
||||
// TODO: In Git, a distinct authorship date is available. When present,
|
||||
// we should show it here.
|
||||
|
||||
$author_epoch = $data->getCommitDetail('authorEpoch');
|
||||
if ($author_epoch !== null) {
|
||||
$authored_info->setNote(
|
||||
phabricator_datetime($author_epoch, $viewer));
|
||||
}
|
||||
|
||||
if ($author_phid) {
|
||||
$authored_info->setTarget($handles[$author_phid]->renderLink());
|
||||
|
||||
Reference in New Issue
Block a user