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

sort: allow -f to be pass multiple time #5681

Conversation

just1602
Copy link
Contributor

@just1602 just1602 commented Dec 20, 2023

Hello 👋

This small PR try to fix #5667.

I'm pretty new to rust, so if there's a better way to allow a flag to be pass multiple time, let me know. 😄

echo "foo" | target/debug/sort -f -f
foo

@tertsdiepraam
Copy link
Member

Thanks! Yeah, there is a better way, although you would've needed to know clap pretty well to find it 😄 You can check out this PR as an example: #5671. As a bonus it will work for all arguments if we do it that way.

Copy link
Member

@tertsdiepraam tertsdiepraam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comment above

@sylvestre
Copy link
Contributor

and with a test to make sure we don't regress please :)

@just1602 just1602 force-pushed the 5667_sort_should_accept_multiple_ignore_case_flag branch from 5b7e3a9 to 2cc487c Compare December 20, 2023 17:35
@just1602 just1602 force-pushed the 5667_sort_should_accept_multiple_ignore_case_flag branch from 2cc487c to a6ba81d Compare December 20, 2023 17:43
@uutils uutils deleted a comment from github-actions bot Dec 20, 2023
Copy link

GNU testsuite comparison:

Skipping an intermittent issue tests/tail/inotify-dir-recreate

Copy link
Member

@tertsdiepraam tertsdiepraam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent!

@tertsdiepraam tertsdiepraam merged commit 8ede759 into uutils:main Dec 21, 2023
@just1602 just1602 deleted the 5667_sort_should_accept_multiple_ignore_case_flag branch December 21, 2023 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sort -f -f should be accepted
3 participants