Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:53701 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 11317 invoked from network); 30 Jun 2011 11:24:30 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 30 Jun 2011 11:24:30 -0000 Authentication-Results: pb1.pair.com header.from=derick@php.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=derick@php.net; spf=unknown; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 82.113.146.227 as permitted sender) X-PHP-List-Original-Sender: derick@php.net X-Host-Fingerprint: 82.113.146.227 xdebug.org Linux 2.6 Received: from [82.113.146.227] ([82.113.146.227:57280] helo=xdebug.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 67/65-10401-DEC5C0E4 for ; Thu, 30 Jun 2011 07:24:29 -0400 Received: from localhost (xdebug.org [127.0.0.1]) by xdebug.org (Postfix) with ESMTPS id 45E7910DC24; Thu, 30 Jun 2011 12:24:26 +0100 (BST) Date: Thu, 30 Jun 2011 12:24:26 +0100 (BST) X-X-Sender: derick@whisky To: =?UTF-8?Q?Johannes_Schl=C3=BCter?= cc: =?UTF-8?Q?David_Z=C3=BClke?= , Arpad Ray , internals@lists.php.net In-Reply-To: <1309431260.2984.2.camel@guybrush> Message-ID: References: <1309303149.2331.119.camel@guybrush> <1309431260.2984.2.camel@guybrush> User-Agent: Alpine 2.02 (DEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="8323328-926392150-1309433066=:3774" Subject: Re: [PHP-DEV] [PATCH] Friendly log messages for CLI server From: derick@php.net (Derick Rethans) --8323328-926392150-1309433066=:3774 Content-Type: TEXT/PLAIN; charset=UTF-8 Content-Transfer-Encoding: QUOTED-PRINTABLE On Thu, 30 Jun 2011, Johannes Schl=C3=BCter wrote: > On Thu, 2011-06-30 at 07:08 +0200, David Z=C3=BClke wrote: > > On 29.06.2011, at 01:19, Johannes Schl=C3=BCter wrote: > >=20 > > > On Tue, 2011-06-28 at 23:37 +0100, Arpad Ray wrote: > > >> - Colours messages according to their response code (success=3Dgreen= , > > >> client error=3Dyellow, server error=3Dred) > > >=20 > > > I would prefer if this would be an ini option (if (cli_web_server.col= or > > > && isatty) color =3D true) default can be on, but I've seen cases whe= re > > > such magic failed and created hard-to use results (due to control > > > sequences in log files or such). > >=20 > > The code could detect if it's outputting to a TTY or not and only use > > color codes if the output isn't redirected somewhere else. >=20 > It *is* checking this. And I showed an example (script(1)) where the > environment pretends to be a TTY and isn't. My suggestion was to add an > ini option in addition to the check. I'm fine with that, but let's leave it set to 1 by default? People with=20 complex requirements can then turn it off if they want to. regards, Derick --8323328-926392150-1309433066=:3774--