diff options
author | Urban Müller | 2020-03-10 14:21:04 +0100 |
---|---|---|
committer | Urban Müller | 2020-03-10 14:21:04 +0100 |
commit | 5d9bf1534f8bd6e277f7f7e45310e028e3f2cca6 (patch) | |
tree | cf560349902e3861cb1acf27691e84e62c308ba1 /it.class | |
parent | 61f113ed37870a1d5865b5bd0ba09ed1b7f4e415 (diff) | |
download | itools-5d9bf1534f8bd6e277f7f7e45310e028e3f2cca6.tar.gz itools-5d9bf1534f8bd6e277f7f7e45310e028e3f2cca6.tar.bz2 itools-5d9bf1534f8bd6e277f7f7e45310e028e3f2cca6.zip |
handle = in short opts as well (-n=2)
Diffstat (limited to 'it.class')
-rw-r--r-- | it.class | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -903,7 +903,9 @@ static function getopt($usage, $p = array()) foreach (explode("\n", trim(chunk_split($letters, 1, "\n"))) as $letter) { $optname = $alias[$letter] ? $alias[$letter] : $letter; - if ($witharg[$optname]) + if ($witharg[$optname] && it::match('=', $arg)) + $result[$optname] = it::match('=(.*)', $arg); + else if ($witharg[$optname]) $eat[] = $optname; else if (!isset($witharg[$optname])) $err = true; |