Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.9.0

Request #3656 usability patch
Submitted: 2005-03-01 09:35 UTC
From: techtonik Assigned: davey
Status: Closed Package: PHP_CompatInfo
PHP Version: Irrelevant OS:
Roadmaps: (Not assigned)    
Subscription  


 [2005-03-01 09:35 UTC] techtonik
Description: ------------ These two little modifications can help people start using Cli.php utility immediately without the need in online docs. 1. Include trivial usage examle in Cli.php header file 2. Make Cli.php display command line help if no command if given (like in trivial example) Reproduce code: --------------- --- Cli_old.php 2005-03-01 10:51:18.000000000 +0200 +++ Cli.php 2005-03-01 11:28:48.000000000 +0200 @@ -20,6 +20,17 @@ /** * CLI Script to Check Compatibility of chunk of PHP code + * + * Example: + * <code> + * <?php + * require_once 'PHP/CompatInfo/Cli.php'; + * + * $cli = new PHP_CompatInfo_Cli(); + * $cli->run(); + * ?> + * </code> + * * @package PHP_CompatInfo * @category PHP */ @@ -160,6 +171,8 @@ } elseif (isset($this->file)) { $output = $this->_parseFile(); echo $output; + } else { + $this->_printHelp(); } } }

Comments

 [2005-03-06 00:19 UTC] davey
This bug has been fixed in CVS. In case this was a documentation problem, the fix will show up at the end of next Sunday (CET) on pear.php.net. In case this was a pear.php.net website problem, the change will show up on the website in short time. Thank you for the report, and for helping us make PEAR better. I've added this request, good ideas. Thanks :) - Davey