projects
/
pharext
/
pharext
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
| inline |
side by side
better help for positional args
[pharext/pharext]
/
src
/
pharext
/
Cli
/
Args.php
diff --git
a/src/pharext/Cli/Args.php
b/src/pharext/Cli/Args.php
index c248a74dcc964c81c089d1b2204a8cacfe3dcfb0..7334290f4f070c8b2f5f5474fc619bf6b7a4eb8a 100644
(file)
--- a/
src/pharext/Cli/Args.php
+++ b/
src/pharext/Cli/Args.php
@@
-207,7
+207,7
@@
class Args implements \ArrayAccess
$args = [];
foreach ($this->spec as $spec) {
$opt = $this->opt($spec[1]);
- $args[$opt] = $this[$opt];
+ $args[$opt] =
is_numeric($spec[0]) ? $this[$spec[0]] :
$this[$opt];
}
return $args;
}