cleo icon indicating copy to clipboard operation
cleo copied to clipboard

HELP: How to remove default flags "--quiet, --version, --ansi, --no-ansi, --no-interaction, --verbose" from commands?

Open marcosdotme opened this issue 2 years ago • 3 comments

How to remove the default "--quiet, --version, --ansi, --no-ansi, --no-interaction, --verbose" flags from a custom command that inherites from "from cleo.commands.command import Command", like the GreetCommand showed in the demo on README?

I created a command and don't want to show these default flags to users.

marcosdotme avatar Jan 19 '23 15:01 marcosdotme

This is currently not available.

Secrus avatar Jan 22 '23 21:01 Secrus

Could you show me where in the code these flags are created? So I could add this functionality of suppressing the flags.

marcosdotme avatar Jan 23 '23 17:01 marcosdotme

Could you show me where in the code these flags are created? So I could add this functionality of suppressing the flags.

https://github.com/python-poetry/cleo/blob/675ec7e1d89aa65ce6dbca0938a89b4788db1045/src/cleo/application.py#L549

tkuipers avatar Apr 10 '23 13:04 tkuipers