Skip to content

Commit e77d501

Browse files
author
epriestley
committed
Fix two issues with shell/config scripts for hosted repositories
Summary: Ref T4151. `-ne` is numeric in some/most/all shells; `exec --` apparently doens't always work. Test Plan: Will make @Zeeg test. Reviewers: btrahan, zeeg Reviewed By: zeeg CC: zeeg, aran Maniphest Tasks: T4151 Differential Revision: https://secure.phabricator.com/D7702
1 parent ff4e965 commit e77d501

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

resources/sshd/phabricator-ssh-hook.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ VCSUSER="vcs-user"
66
# NOTE: Replace this with the path to your Phabricator directory.
77
ROOT="/path/to/phabricator"
88

9-
if [ "$1" -ne "$VCSUSER" ];
9+
if [ "$1" != "$VCSUSER" ];
1010
then
1111
exit 1
1212
fi

src/applications/repository/engine/PhabricatorRepositoryPullEngine.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ private function installHook($path) {
162162

163163
$root = dirname(phutil_get_library_root('phabricator'));
164164
$bin = $root.'/bin/commit-hook';
165-
$cmd = csprintf('exec -- %s %s "$@"', $bin, $callsign);
165+
$cmd = csprintf('exec %s %s "$@"', $bin, $callsign);
166166

167167
$hook = "#!/bin/sh\n{$cmd}\n";
168168

0 commit comments

Comments
 (0)