mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 03:27:44 +00:00
sort: dedup using compare_by (#2064)
compare_by is the function used for sorting, we should use it for dedup as well.
This commit is contained in:
parent
49c9d8c901
commit
69f4410a8a
8 changed files with 28 additions and 71 deletions
2
tests/fixtures/sort/numeric_unique.expected
vendored
Normal file
2
tests/fixtures/sort/numeric_unique.expected
vendored
Normal file
|
@ -0,0 +1,2 @@
|
|||
-10 bb
|
||||
aa
|
3
tests/fixtures/sort/numeric_unique.txt
vendored
Normal file
3
tests/fixtures/sort/numeric_unique.txt
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
aa
|
||||
-10 bb
|
||||
-10 aa
|
3
tests/fixtures/sort/words_unique.expected
vendored
Normal file
3
tests/fixtures/sort/words_unique.expected
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
aaa
|
||||
bbb
|
||||
zzz
|
4
tests/fixtures/sort/words_unique.txt
vendored
Normal file
4
tests/fixtures/sort/words_unique.txt
vendored
Normal file
|
@ -0,0 +1,4 @@
|
|||
zzz
|
||||
aaa
|
||||
bbb
|
||||
bbb
|
Loading…
Add table
Add a link
Reference in a new issue