Closed
Description
Q | A |
---|---|
Bug report? | no |
Feature request? | yes |
BC Break report? | no |
RFC? | yes |
Symfony version | 3.4 |
With PSR-4-based service definitions, we can declare command as services. But this doesn't provide laziness for them, because we don't know their name at compile time.
To enhance that, what about adding a new static method + related interface to commands, ?
Eg.
public static function getDefaultName()
{
return 'foo:bar';
}
That would also enable auto-configuration of commands. The method would be called to fill in the "name" attribute of the "console.command" tag when none is set.
ping @chalasr
Metadata
Metadata
Assignees
Labels
RFC = Request For Comments (proposals about features that you want to be discussed)RFC = Request For Comments (proposals about features that you want to be discussed)