mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2026-01-17 10:41:03 +00:00
Made a new function sort_by(lines, compare_fns), which accepts a list of compare_fns and calls lines.sort_by() with a closure that calls each compare_fn in turn until one returns something other than equal. Default behavior ensures that String::cmp is the last element in the compare_fns list (referred to as 'last resort' sorting by man sort). Passing --stable (-s) turns this behaviour off. Test cases provided for `sort --month` and `sort --month --stable`. |
||
|---|---|---|
| .. | ||
| check_fail.txt | ||
| default_unsorted_ints.expected | ||
| default_unsorted_ints.txt | ||
| human_block_sizes.expected | ||
| human_block_sizes.txt | ||
| month_default.expected | ||
| month_default.txt | ||
| month_stable.expected | ||
| month_stable.txt | ||
| multiple_files.expected | ||
| multiple_files1.txt | ||
| multiple_files2.txt | ||
| numeric_fixed_floats.expected | ||
| numeric_fixed_floats.txt | ||
| numeric_floats.expected | ||
| numeric_floats.txt | ||
| numeric_floats_and_ints.expected | ||
| numeric_floats_and_ints.txt | ||
| numeric_unfixed_floats.expected | ||
| numeric_unfixed_floats.txt | ||
| numeric_unsorted_ints.expected | ||
| numeric_unsorted_ints.txt | ||
| numeric_unsorted_ints_unique.expected | ||
| numeric_unsorted_ints_unique.txt | ||
| version.expected | ||
| version.txt | ||