From 61b79b5359a6408802cd3406df7bc0e0844735f7 Mon Sep 17 00:00:00 2001 From: Jason Ge Date: Tue, 3 Jul 2012 13:41:11 -0700 Subject: [PATCH] Use binary_safe_diff from arcanist Summary: binary_safe_diff is needed in arcanist too. Moved it over to arcanist. See D2915. Test Plan: diffusion page rendered correctly on binary file. Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D2916 --- scripts/repository/binary_safe_diff.sh | 6 ------ .../diffusion/query/rawdiff/DiffusionSvnRawDiffQuery.php | 4 ++-- 2 files changed, 2 insertions(+), 8 deletions(-) delete mode 100755 scripts/repository/binary_safe_diff.sh diff --git a/scripts/repository/binary_safe_diff.sh b/scripts/repository/binary_safe_diff.sh deleted file mode 100755 index 1473e80442..0000000000 --- a/scripts/repository/binary_safe_diff.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -diff "$@" -if [ "$?" = "2" ]; then - exit 1 -fi diff --git a/src/applications/diffusion/query/rawdiff/DiffusionSvnRawDiffQuery.php b/src/applications/diffusion/query/rawdiff/DiffusionSvnRawDiffQuery.php index d091792a0c..f3907ed1d8 100644 --- a/src/applications/diffusion/query/rawdiff/DiffusionSvnRawDiffQuery.php +++ b/src/applications/diffusion/query/rawdiff/DiffusionSvnRawDiffQuery.php @@ -23,11 +23,11 @@ final class DiffusionSvnRawDiffQuery extends DiffusionRawDiffQuery { $repository = $drequest->getRepository(); $commit = $drequest->getCommit(); - $root = phutil_get_library_root('phabricator'); + $arc_root = phutil_get_library_root('arcanist'); $future = $repository->getRemoteCommandFuture( 'diff --diff-cmd %s -x -U%d -c %d %s%s@', - $root.'/../scripts/repository/binary_safe_diff.sh', + $arc_root.'/../scripts/repository/binary_safe_diff.sh', $this->getLinesOfContext(), $commit, $repository->getRemoteURI(),