diff options
author | Christian Helbling | 2018-10-08 09:15:19 +0200 |
---|---|---|
committer | Christian Helbling | 2018-10-08 09:15:19 +0200 |
commit | 51ed968a13e1664bd256e2adafcb1d5e3c4f4095 (patch) | |
tree | 976e16740ebaf651390435f80a1253252aa57e3a /it.class | |
parent | adadae917b981ec4cccc29951a0bf22edb8fe380 (diff) | |
download | itools-51ed968a13e1664bd256e2adafcb1d5e3c4f4095.tar.gz itools-51ed968a13e1664bd256e2adafcb1d5e3c4f4095.tar.bz2 itools-51ed968a13e1664bd256e2adafcb1d5e3c4f4095.zip |
put behaviour of --debug in it::getopt into it_debug::set so we can use that in other places as well - for example in runtests
Diffstat (limited to 'it.class')
-rw-r--r-- | it.class | 11 |
1 files changed, 1 insertions, 10 deletions
@@ -902,16 +902,7 @@ static function getopt($usage, $p = array()) } if ($result['debug']) - { - foreach (preg_split('/[.,]/', $result['debug']) as $ultrad) - { - $ultravar = preg_split('/[-=:]/', $ultrad, 2); - $GLOBALS["debug_$ultravar[0]"] = isset($ultravar[1]) ? $ultravar[1] : 1; - } - - # keep debug parameters in subrequests - $_SERVER['ULTRAHOSTNAME'] = it::replace(['^\.+' => '', '([^.])\.*$' => '\1.'], $result['debug']) . $_SERVER['ULTRAHOSTNAME']; - } + it_debug::set($result['debug']); $GLOBALS['it_stdin']['args'] = $result['args'] ? $result['args'] : array("-"); it::_stdin_next(); |