Repository navigation
v0.14.0
New features and enhancements
- You can show a "Positional arguments" help section by passing a non-empty
helpdescription for at least one of the arguments of a command/group. #113 cloup.Groupnow extendscloup.Commandand, as a consequence, supports option groups and constraints. #113GroupedOptionis now an alias ofcloup.Option.- Add the new
paramsClick argument to@commandand@groupsignatures. This argument is supported only for click >= 8.1.0. See
pallets/click#2203.
Breaking changes
This release introduces some breaking changes, but nothing relevant for most users. You'll need to make changes if you've imported and used Cloup mixins directly, for example in order to add support for option groups and constraints to Group (now you can just use cloup.Group).
BaseCommandwas removed. This shouldn't cause any issue to anybody.cloup.Groupextendscloup.Command, similarly asclick.Groupextendsclick.Command.OptionGroupMixin.format_optionswas renamed toformat_params. This means you can't just mix it withclick.Commandto print help sections for option groups, you have to overrideformat_helpand callformat_params.- The new
format_paramsdoesn't callsuper().format_commandsasformat_optionsdid: that's what Click does and Cloup (reluctantly) did. Now, instead,cloup.Commandcallsformat_paramsinformat_helpand then, for multi-commands, callsformat_commandsdirectly. ConstraintMixin.format_helpwas removed. This means you can't just mix it with a click.Command to make it print the "Constraints" help section, you need to callformat_constraintsexplicitly in your commandformat_help.
On the website: https://cloup.readthedocs.io/en/v0.14.0/pages/changelog.html#v0-14-0-2022-05-09
All commits: v0.13.1...v0.14.0