mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2026-01-15 01:31:08 +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`. |
||
|---|---|---|
| .. | ||
| Cargo.toml | ||
| main.rs | ||
| sort.rs | ||