mirror of
https://github.com/phabelio/PHP-Parser.git
synced 2024-11-30 04:29:15 +01:00
support -h and --help standard options
This commit is contained in:
parent
e7f0860d85
commit
d1dd9f5aec
@ -101,6 +101,7 @@ Operations is a list of the following options (--dump by default):
|
|||||||
--var-dump var_dump() nodes (for exact structure)
|
--var-dump var_dump() nodes (for exact structure)
|
||||||
-N, --resolve-names Resolve names using NodeVisitor\NameResolver
|
-N, --resolve-names Resolve names using NodeVisitor\NameResolver
|
||||||
-c, --with-column-info Show column-numbers for errors (if available)
|
-c, --with-column-info Show column-numbers for errors (if available)
|
||||||
|
-h, --help Display this page
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
php-parse -d -p -N -d file.php
|
php-parse -d -p -N -d file.php
|
||||||
@ -150,6 +151,10 @@ function parseArgs($args) {
|
|||||||
case '-c';
|
case '-c';
|
||||||
$attributes['with-column-info'] = true;
|
$attributes['with-column-info'] = true;
|
||||||
break;
|
break;
|
||||||
|
case '--help':
|
||||||
|
case '-h';
|
||||||
|
showHelp('');
|
||||||
|
break;
|
||||||
case '--':
|
case '--':
|
||||||
$parseOptions = false;
|
$parseOptions = false;
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user