Page MenuHomePhabricator

Add option to set default ordering of files in diff review
Closed, WontfixPublic

Description

Currently the ordering of a diff seems to be alphabetical based on file paths. However, if our source files are in a folder that starts with "XYZ", then we might also have unit tests in a folder called "Tests", and thus in all our diffs the first thing to appear are changes to the unit tests. A diff might be more focused if the first thing a user sees were changes to source code in "XYZ" rather than unit tests in "Tests".

Event Timeline

ebgraham raised the priority of this task from to Needs Triage.
ebgraham updated the task description. (Show Details)
ebgraham added a subscriber: ebgraham.
epriestley claimed this task.
epriestley added a subscriber: epriestley.

This would be complex to implement (sorting isn't, per se, but proper implementation which consistently extends to Differential, Diffusion, Owners, arc, etc.) and this use case doesn't seem very strong (the behavior is obvious, there's a table of contents and a scrollbar, there's no particular reason not to review tests first, etc.).

If this is a major issue, consider putting tests in a directory called zzztests or similar. Notably, Facebook used a directory named zeusgodofthunder/ to hold subproject code for a long period of time after users complained that the previous, more accurate name was disrupting tab completion.

Unfortunate to see this closed. This is actually a major complaint among developers in our org, since our company name starts with "U". iPhone developers will also understand the annoyance of seeing the massive and often irrelevant project.pbxproj appear before source files in the diff.

iPhone developers will also understand the annoyance of seeing the massive and often irrelevant project.pbxproj appear before source files in the diff.

You can use differential.generated-paths to mark files as generated code, which will automatically fold them during review.