1 |
Peter Abrahamsen wrote: |
2 |
> Hi Andrew, |
3 |
> |
4 |
> I'm not aware of any way to do this. At my last job we focused on |
5 |
> making sure syntax errors never get into the repository, which was |
6 |
> easy to do. We had a pre-commit hook that ran .php files through php |
7 |
> -l (lint mode). If that failed, the commit was rejected. I had another |
8 |
> hook that made sure all the files contained only valid unicode. |
9 |
|
10 |
That actually does help me some. I didn't know about php's lint mode. I ran it |
11 |
on all the .php files in this particular site ("find /var/www/<domain>/htdocs |
12 |
-name '*.php' -exec php -l {} \;" for anyone that's curious) and didn't come up |
13 |
with anything. |
14 |
|
15 |
This all started when one of our order takers told me they got a call from |
16 |
someone who said they got a parse error on our site, but I didn't have any more |
17 |
information than that. I clicked around, but didn't hit any problems. |
18 |
|
19 |
I still don't see any problems, but at least now I have peace of mind :) |
20 |
|
21 |
-- |
22 |
Andrew Gaffney http://dev.gentoo.org/~agaffney/ |
23 |
Gentoo Linux Developer Catalyst/Installer + x86 release coordinator |
24 |
-- |
25 |
gentoo-server@g.o mailing list |