Summary:
`svn rm $directory` removes the directory and its contents in svn 1.7, whereas
svn 1.6 only removes the directory's contents, so arc diff needs to not try
to read the directory.
Test Plan:
ran arc diff in a svn working copy that had a directory removed (with both
svn 1.6 and svn 1.7) and confirmed that the command did not throw an exception,
and that the removed directory was marked as directory (not a file).
Reviewers: epriestley, jungejason
Reviewed By: epriestley
CC: aran, epriestley
Differential Revision: https://secure.phabricator.com/D1889
$from[$path] = $cpath;
}
+ $type = $change->getType();
+ if (($type === ArcanistDiffChangeType::TYPE_MOVE_AWAY ||
+ $type === ArcanistDiffChangeType::TYPE_DELETE) &&
+ idx($info, 'Node Kind') === 'directory') {
+ $change->setFileType(ArcanistDiffChangeType::FILE_DIRECTORY);
+ }
}
foreach ($paths as $path => $status) {
'/^(Copied From URL): (\S+)$/m',
'/^(Copied From Rev): (\d+)$/m',
'/^(Repository UUID): (\S+)$/m',
+ '/^(Node Kind): (\S+)$/m',
);
$result = array();
return null;
}
+ if (!file_exists($full_path)) {
+ return null;
+ }
+
$data = Filesystem::readFile($full_path);
$lines = explode("\n", $data);
$len = count($lines);
return null;
}
+ if (!file_exists($full_path)) {
+ return null;
+ }
+
$change = $this->getChange($path);
if ($change->getFileType() !== ArcanistDiffChangeType::FILE_TEXT) {