Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15283176
D7790.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D7790.id.diff
View Options
Index: src/parser/ArcanistDiffParser.php
===================================================================
--- src/parser/ArcanistDiffParser.php
+++ src/parser/ArcanistDiffParser.php
@@ -207,6 +207,8 @@
$patterns = array(
// This is a normal SVN text change, probably from "svn diff".
'(?P<type>Index): (?P<cur>.+)',
+ // This is an SVN text change, probably from "svnlook diff".
+ '(?P<type>Modified|Added|Deleted): (?P<cur>.+)',
// This is an SVN property change, probably from "svn diff".
'(?P<type>Property changes on): (?P<cur>.+)',
// This is a git commit message, probably from "git show".
@@ -285,6 +287,9 @@
switch ($match['type']) {
case 'Index':
+ case 'Modified':
+ case 'Added':
+ case 'Deleted':
$this->parseIndexHunk($change);
break;
case 'Property changes on':
Index: src/parser/__tests__/ArcanistDiffParserTestCase.php
===================================================================
--- src/parser/__tests__/ArcanistDiffParserTestCase.php
+++ src/parser/__tests__/ArcanistDiffParserTestCase.php
@@ -570,6 +570,11 @@
ArcanistDiffChangeType::TYPE_CHANGE,
$change->getType());
break;
+ case 'svnlook-basics.svndiff':
+ case 'svnlook-add.svndiff':
+ case 'svnlook-delete.svndiff':
+ $this->assertEqual(1, count($changes));
+ break;
default:
throw new Exception("No test block for diff file {$diff_file}.");
break;
Index: src/parser/__tests__/diff/svnlook-add.svndiff
===================================================================
--- /dev/null
+++ src/parser/__tests__/diff/svnlook-add.svndiff
@@ -0,0 +1,7 @@
+Added: OTHER
+===================================================================
+--- OTHER (rev 0)
++++ OTHER 2013-12-18 21:00:43 UTC (txn 18-y)
+@@ -0,0 +1 @@
++other
+
Index: src/parser/__tests__/diff/svnlook-basics.svndiff
===================================================================
--- /dev/null
+++ src/parser/__tests__/diff/svnlook-basics.svndiff
@@ -0,0 +1,10 @@
+Modified: README
+===================================================================
+--- README 2013-12-18 20:56:12 UTC (rev 17)
++++ README 2013-12-18 20:56:47 UTC (txn 17-x)
+@@ -17,3 +17,4 @@
+ j
+ j
+ j
++j
+
Index: src/parser/__tests__/diff/svnlook-delete.svndiff
===================================================================
--- /dev/null
+++ src/parser/__tests__/diff/svnlook-delete.svndiff
@@ -0,0 +1,7 @@
+Deleted: OTHER
+===================================================================
+--- OTHER 2013-12-18 21:00:43 UTC (rev 19)
++++ OTHER 2013-12-18 21:01:18 UTC (txn 19-z)
+@@ -1 +0,0 @@
+-other
+
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Mar 5, 5:48 AM (3 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7223688
Default Alt Text
D7790.id.diff (2 KB)
Attached To
Mode
D7790: Parse the output of `svnlook diff ...`
Attached
Detach File
Event Timeline
Log In to Comment