MCPcopy
hub / github.com/pallets/click / make_formatter

Method make_formatter

src/click/core.py:630–642  ·  view source on GitHub ↗

Creates the :class:`~click.HelpFormatter` for the help and usage output. To quickly customize the formatter class used without overriding this method, set the :attr:`formatter_class` attribute. .. versionchanged:: 8.0 Added the :attr:`formatter_class` at

(self)

Source from the content-addressed store, hash-verified

628 return self._meta
629
630 def make_formatter(self) -> HelpFormatter:
631 """Creates the :class:`~click.HelpFormatter` for the help and
632 usage output.
633
634 To quickly customize the formatter class used without overriding
635 this method, set the :attr:`formatter_class` attribute.
636
637 .. versionchanged:: 8.0
638 Added the :attr:`formatter_class` attribute.
639 """
640 return self.formatter_class(
641 width=self.terminal_width, max_width=self.max_content_width
642 )
643
644 def with_resource(self, context_manager: AbstractContextManager[V]) -> V:
645 """Register a resource as if it were used in a ``with``

Callers 2

get_usageMethod · 0.80
get_helpMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected