Instead of adding it as a php ini option, please consider adding this as a
parameter to the php-cli executable as this might be something you would
want to enable/disable quickly per instance. This would also make the
coloring output more attractive to use instead of having to edit the ini
file every time or have a seperate ini file just for the purpose to enable
or disable coloring
Den 30/06/2011 12.54 skrev "Johannes Schlüter" johannes@schlueters.de:
Instead of adding it as a php ini option, please consider adding this as a
parameter to the php-cli executable as this might be something you would
want to enable/disable quickly per instance. This would also make the
coloring output more attractive to use instead of having to edit the ini
file every time or have a seperate ini file just for the purpose to enable
or disable coloring
Then you would be forced to always pass that option.
If you want to enable it for one run you could do
php -dcli.color=0 foo.php
No need to edit the ini.
-Hannes
Instead of adding it as a php ini option, please consider adding this as a
parameter to the php-cli executable as this might be something you would
want to enable/disable quickly per instance. This would also make the
coloring output more attractive to use instead of having to edit the ini
file every time or have a seperate ini file just for the purpose to enable
or disable coloringThen you would be forced to always pass that option.
If you want to enable it for one run you could do
php -dcli.color=0 foo.phpNo need to edit the ini.
-Hannes
If we have to have colouring at all, then I'd prefer a php.ini option
to a command line option. The default should be coded Off, but can be
set On in the php.ini-development file we ship.
Preferably the parameter would be non-binary. This allows someone to
extend it, including adding alternative colour schemes for the
red-green impaired person:
cli.webserver_log = COLOR_NONE
cli.webserver_log = COLOR_REDGREEN ; uses red & green
cli.webserver_log = COLOR_YELLOWBLUE ; uses yellow & blue
cli.webserver_log = COLOR_REDGREEN | ERRORS_ONLY ; you get the idea
Chris
--
Email: christopher.jones@oracle.com
Tel: +1 650 506 8630
Blog: http://blogs.oracle.com/opal/
Hi,
There's now a request for this:
https://bugs.php.net/bug.php?id=55109
Colours are now toggled by the ini setting cli_server.color.
I'm still looking into means of excluding the more deceptively
incapable terminals but I will support having colours on by default
anyway.
Regards,
Arpad