From b6920b7ca8a6859bf9f76247b882dbd9331a9c78 Mon Sep 17 00:00:00 2001 From: Chris Smith Date: Sat, 3 Apr 2010 02:12:21 +0100 Subject: [PATCH] [git-tools] Use env to find the correct paths to binaries. --- git-tools/hooks/pre-commit | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/git-tools/hooks/pre-commit b/git-tools/hooks/pre-commit index a7deea43c5..151c604c30 100755 --- a/git-tools/hooks/pre-commit +++ b/git-tools/hooks/pre-commit @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # A hook to disallow php syntax errors to be committed # by running php -l (lint) on them. It requires php-cli @@ -53,7 +53,7 @@ do # check the staged file content for syntax errors # using php -l (lint) - result=$(git cat-file -p $sha | $PHP_BIN -l) + result=$(git cat-file -p $sha | /usr/bin/env $PHP_BIN -l) if [ $? -ne 0 ] then error=1