1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2025-01-16 17:51:10 +01:00
phorge-arcanist/src/repository
Evan Priestley 97501da164 Fix double file content in files in new subdirectories in Subversion
Summary:
Fixes T5555. Normally, when we `svn diff subdir/`, we use `--depth empty` to get only changes for the directory itself (usually, property changes).

However, this flag has no effect if the directory is newly added.

Adjust the diff parser so that if two sets of hunks are specified for a single file in a raw diff, we let the last one win instead of including both. This approach is a broadly more reasonable interpretation of these diffs.

Test Plan:
  - Added a new file in a new subdirectory in Subversion.
  - Ran `arc diff --only`.
  - No double file content in resulting diff.
  - Added unit test.
  - There's fairly comprehensive unit test coverage for this stuff.

Reviewers: btrahan, chad

Reviewed By: chad

Subscribers: epriestley

Maniphest Tasks: T5555

Differential Revision: https://secure.phabricator.com/D9921
2014-07-15 09:43:04 -07:00
..
api Fix double file content in files in new subdirectories in Subversion 2014-07-15 09:43:04 -07:00
hookapi Remove @group annotations 2014-07-09 09:12:13 +10:00
parser Remove @group annotations 2014-07-09 09:12:13 +10:00