feat: Add --sort arg to CLI to sort by path/size/dates#1982
feat: Add --sort arg to CLI to sort by path/size/dates#1982DeflateAwning wants to merge 20 commits intosharkdp:masterfrom
Conversation
tmccombs
left a comment
There was a problem hiding this comment.
If a sorting feature is added to fd, it will need to have very minimal impact on flows that don't use sort, and shouldn't significantly add to the complexity and maintenance burden of the project.
This isn't there (yet).
There was a problem hiding this comment.
This implementation requires sorting to be handled by every output path. That adds complexity and makes it harder to maintain.
It would be better if there is some way we could avoid needing separate sorting logic for --exec, --exec-batch, and printing.
|
Thank you for the review! One or two days and I'll have another version to look over. |
Co-authored-by: Thayne McCombs <astrothayne@gmail.com>
…ring) - review comment
|
@tmccombs Thanks again for the review/suggestions. Would you mind taking another look? It's getting closer, I think. Regarding the "one code path" suggestion - I'm open to ideas. I think it's reasonably DRYed right now. The alternative implementation I thought of involves piping the iterator through something like |
Resolves #1875