Re: cvs: phd / config.php

From: Date: Mon, 05 Nov 2007 10:00:57 +0000
Subject: Re: cvs: phd / config.php
References: 1  Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-343@lists.php.net to get a copy of this message
For windows users ^ is the escape character to use (in case you didn't know). e.g. --verbose VERBOSE_INDEXING^|VERBOSE_FORMAT_RENDERING On 05/11/2007, Hannes Magnusson <bjori@php.net> wrote: > bjori Mon Nov 5 09:49:45 2007 UTC > > Modified files: > /phd config.php > Log: > Added support for the VERBOSE_* constants as arguments > # You can | them together - but you obviously need to escape | from your shell :) > > > > > http://cvs.php.net/viewvc.cgi/phd/config.php?r1=1.9&r2=1.10&diff_format=u > Index: phd/config.php > diff -u phd/config.php:1.9 phd/config.php:1.10 > --- phd/config.php:1.9 Mon Nov 5 08:41:04 2007 > +++ phd/config.php Mon Nov 5 09:49:45 2007 > @@ -1,5 +1,5 @@ > <?php > -/* $Id: config.php,v 1.9 2007/11/05 08:41:04 bjori Exp $ */ > +/* $Id: config.php,v 1.10 2007/11/05 09:49:45 bjori Exp $ */ > > function v($msg) { > $args = func_get_args(); > @@ -159,12 +159,16 @@ > > /* {{{ Verbosity level */ > case "verbose": > - if (is_array($v)) { > - foreach($v as $i => $val) { > - $verbose |= (int)$val; > + foreach((array)$v as $i => $val) { > + foreach(explode("|", $val) as $const) { > + if (defined($const)) { > + $verbose |= (int)constant($const); > + } elseif (is_numeric($const)) { > + $verbose |= (int)$const; > + } else { > + v("Unkown option passed to --$k, $const\n"); > + } > } > - } else { > - $verbose |= (int)$v; > } > $OPTIONS["verbose"] = $verbose; > break; > > -- > PHP Documentation Commits Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- ----- Richard Quadling Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731 "Standing on the shoulders of some very clever giants!"

« previous php.doc.cvs (#343) next »