Why is setting values not permitted?
I want to use a "--dry" flag that will automatically activate few other options via boolean flags, so the user doesn't have to type 3 switches but just to use one.
$command= new Commando\Command();
// some options are defined here
//--dry flag should enable --skip --run --show flags
if ($command['dry']) {
$command['skip'] = true;
$command['run'] = true;
$command['show'] = true;
}
Fatal error: Uncaught Exception: Setting an option value via array syntax is not permitted in C:\......1
Stack trace:
Is there any workaround? Like get a copy of parsed options as array and then overrwrite?
Hi
Why is setting values not permitted? I want to use a "--dry" flag that will automatically activate few other options via boolean flags, so the user doesn't have to type 3 switches but just to use one.
Is there any workaround? Like get a copy of parsed options as array and then overrwrite?