-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Description
Problem
In cargo 1.68.1, maybe since the clap v4 upgrade (#11159), help text in --help
output is not wrapping. This looks bad for example in cargo init --help
, because the help text for --vcs
is pretty long and it just wraps at the terminal emulator line end without respecting word boundaries.
Maybe the wrap_help
feature of clap should be enabled? AIUI, it pulls in a new dependency, but the possibility to wrap at a fixed width (e.g. 80 chars) was dropped in clap v3. [max_]term_width
functions apparently exist, but they don't work when the wrap_help
feature is disabled, which it is by default (or maybe I'm misunderstanding this issue).
Proposed Solution
Probably enable the clap wrap_help
feature, or maybe downgrade to clap v3 and set a fixed wrap width of e.g. 80 characters if the additional dependency is too heavy / unwanted.
Notes
No response