1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-01-27 06:58:17 +01:00
phorge-phorge/src/infrastructure/diff
epriestley 92abe3c8fb Extract scope line selection logic from the diff rendering engine so it can reasonably be iterated on
Summary:
Ref T13249. Ref T11738. See PHI985. Currently, we have a crude heuristic for guessing what line in a source file provides the best context.

We get it wrong in a lot of cases, sometimes selecting very silly lines like "{". Although we can't always pick the same line a human would pick, we //can// pile on heuristics until this is less frequently completely wrong and perhaps eventually get it to work fairly well most of the time.

Pull the logic for this into a separate standalone class and make it testable to prepare for adding heuristics.

Test Plan: Ran unit tests, browsed various files in the web UI and saw as-good-or-better context selection.

Reviewers: amckinley

Reviewed By: amckinley

Maniphest Tasks: T13249, T11738

Differential Revision: https://secure.phabricator.com/D20171
2019-02-19 10:55:10 -08:00
..
__tests__ Extract scope line selection logic from the diff rendering engine so it can reasonably be iterated on 2019-02-19 10:55:10 -08:00
interface Build a page for viewing all inline comments 2017-06-12 11:31:20 -07:00
query Publish draft "done" status when submitting comments/updates/actions/inlines 2015-03-24 05:26:12 -07:00
view Allow reviewers to mark their own inlines as "Done" before they submit them 2018-09-07 11:17:42 -07:00
PhabricatorChangesetResponse.php Reduce code duplication for inline "Undo" 2015-03-09 10:26:53 -07:00
PhabricatorDifferenceEngine.php Extend from Phobject 2015-06-15 18:02:27 +10:00
PhabricatorDiffScopeEngine.php Extract scope line selection logic from the diff rendering engine so it can reasonably be iterated on 2019-02-19 10:55:10 -08:00
PhabricatorInlineCommentController.php When authors add inlines to their own revisions/commits, mark them as "Done" by default 2018-09-07 11:18:14 -07:00
PhabricatorInlineCommentPreviewController.php Touch up PHP/JS interactions for inline comments 2015-03-27 17:08:31 -07:00