How would one configure symfony/console
to accept a dynamic list of options?
That said - the names for the options aren't known on development step so I need an application to accept everything and expose it using the standard $input->getOption
.
Any chance it can be done easily (without hacking the component in million places)?
My attempts included extending the ArgvInput
and InputDefinition
classes but they failed due to various reasons (they are objective and symfony/console
component implementation-specific). Briefly: the former requires parsing to be invoked multiple times; the latter - is instantiated in multiple places so I just couldn't find a proper way to inject it.