Skip to content

Version 0.4.0

Choose a tag to compare

@hamdanal hamdanal released this 15 Oct 15:46
· 152 commits to main since this release

What's Changed

Added support for all help formatters of argparse by @hamdanal in #31
There are now five formatter classes defined in rich_argparse

RichHelpFormatter:                 the equivalent of argparse.HelpFormatter
RawDescriptionRichHelpFormatter:   the equivalent of argparse.RawDescriptionHelpFormatter
RawTextRichHelpFormatter:          the equivalent of argparse.RawTextHelpFormatter
ArgumentDefaultsRichHelpFormatter: the equivalent of argparse.ArgumentDefaultsHelpFormatter
MetavarTypeRichHelpFormatter:      the equivalent of argparse.MetavarTypeHelpFormatter

Warning
This changes the default behavior of RichHelpFormatter to no longer respect line breaks in the description and help text. It now behaves similarly to the original argparse.HelpFormatter. You have now to use the appropriate formatter subclass to control line breaks as you would do with argparse formatters.

Full Changelog: v0.3.1...v0.4.0