Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix clap doc-comment #1045

Merged
merged 1 commit into from
Jun 8, 2024
Merged

Fix clap doc-comment #1045

merged 1 commit into from
Jun 8, 2024

Conversation

Long0x0
Copy link
Contributor

@Long0x0 Long0x0 commented May 8, 2024

clap always removes the last single period from a doc-comment.

before:

~$ lsd --help
  -a, --all                          Do not ignore entries starting with

after:

~$ lsd --help
  -a, --all                          Do not ignore entries starting with .

TODO

  • Use cargo fmt
  • Add necessary tests
  • Update default config/theme in README (if applicable)
  • Update man page at lsd/doc/lsd.md (if applicable)

clap always removes the last single period from a doc-comment.
@Long0x0 Long0x0 requested a review from zwpaper as a code owner May 8, 2024 11:38
@muniu-bot muniu-bot bot added the size/XS label May 8, 2024
Copy link

muniu-bot bot commented May 8, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Long0x0
Once this PR has been reviewed and has the lgtm label, please assign zwpaper for approval by writing /assign @zwpaper in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@outloudvi
Copy link

outloudvi commented May 25, 2024

To fix this, Clap also has a flag called verbatim_doc_comment to avoid removing trailing dots and so on, but solution of this PR seems more specific (and not breaking other benefits of Clap's pre-processing).

@zwpaper
Copy link
Member

zwpaper commented Jun 8, 2024

thanks so much for this good and funny catch @outloudvi

@zwpaper zwpaper merged commit 5d02a59 into lsd-rs:master Jun 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants