1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-06-10 16:35:35 +02:00
Commit Graph

22 Commits

Author SHA1 Message Date
300867ab1a [ticket/11630] Improvements to the PHP lint pre-commit hook
The PHP lint pre-commit hook fails to display any output when an error
other than a parse error is decteced.

Additionally, the hook may not display any meaningful output depending
on php.ini settings. This commit removes the dependency on php.ini.

PHPBB3-11630
2013-07-06 12:16:59 -05:00
dc63db1860 [ticket/10760] Fix numbering in php fun facts.
PHPBB3-10760
2012-04-04 11:43:59 -04:00
efdd1e623e [ticket/10760] Value must be quoted as it might be two words.
PHPBB3-10760
2012-04-04 11:41:14 -04:00
6536a36208 [ticket/10760] PHP is great. This commit is the proof.
PHPBB3-10760
2012-04-04 00:27:06 -04:00
f2967b6669 [ticket/10760] Catch both versions of parse error output in php.
PHPBB3-10760
2012-04-04 00:01:08 -04:00
a0da2408e7 [ticket/10760] Account for display_errors=stderr in pre-commit hook.
With that php.ini value set errors are printed to stderr, therefore
by redirecting stderr to /dev/null we also throw out the errors.

Instead merge stderr into stdout.

PHPBB3-10760
2012-04-03 23:18:33 -04:00
b803fc4351 [ticket/10760] Quote PHP_BIN when using it.
This should make a difference on windows where paths may include spaces.

PHPBB3-10760
2012-04-03 23:14:44 -04:00
786fcbf212 [ticket/10760] Use echo -e only if echo understands -e.
/bin/echo on freebsd and dash's builtin echo do not understand -e,
therefore -e is printed with the other messages in such cases.

Test if echo understands -e, if not do not use it.

PHPBB3-10760
2012-04-03 23:06:50 -04:00
57209a1e68 [ticket/10760] Use externally specified PHP_BIN if any.
We have a PHP_BIN variable but we always set it unconditionally,
therefore in order to use a different php binary one had to
modify the hook script.

Instead set PHP_BIN if it is not set.

Now one can set PHP_BIN in their environment to use a non-default
php binary.

PHPBB3-10760
2012-04-03 23:05:15 -04:00
90d8fc7e86 [ticket/9777] Print error message in pre-commit hook when php is not installed.
PHPBB3-9777
2010-08-19 17:44:54 +02:00
9674214b2f [git-tools] Use @ instead of : in sed command in pre-commit hook for wider compatibility. 2010-04-13 21:44:18 +01:00
9afe2c9b6e [git-tools] Adjusted pre-commit hook to run under freebsd /bin/sh. 2010-04-13 21:44:12 +01:00
5a3ec9901d [git-tools] Changed pre-commit hook to use sh instead of bash 2010-04-13 21:44:03 +01:00
11de6a46b1 [git-tools] add note about PHP_BIN using env 2010-04-03 22:06:25 +02:00
8091e31666 [git-tools] do not display stderr 2010-04-03 21:53:09 +02:00
b6920b7ca8 [git-tools] Use env to find the correct paths to binaries. 2010-04-03 02:12:21 +01:00
5568b2134b [git-tools] Display what parse errors were found. 2010-04-03 01:53:12 +01:00
a06ec8c7fd [git-tools] This script requires bash to run, so point directly to bash. 2010-04-03 01:51:37 +01:00
ae48c8ee9e [git-tools] Improvements for the pre-commit hook
One major issue with the pre-hook so far was partially staged files,
because it used filenames for php lint. These changes will make the hook read the file contents from the index instead.

Great thanks to David Soria Parra.
2010-03-17 23:07:57 +01:00
f9192bed79 [git-tools] Some pre-commit enhancements, abolish tempfile 2010-03-11 19:44:21 +01:00
6df10358aa [git-tools] use mktemp in pre-commit (thanks nn-) 2010-03-10 21:37:55 +01:00
db8c557e4c [git-tools] pre-commit hook for syntax checking
This pre-commit hook utilises PHP's command-line -l (lint) option, which
checks for syntax errors. In case of an error the commit is rejected and
the error displayed.

Testing is welcome.
2010-03-10 20:07:10 +01:00