1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-08-01 21:47:46 +00:00

sort: make -k only take one argument per flag

This makes it so that `sort -k 1 file` treats `file` as the input file
and not the second key.
This commit is contained in:
Michael Debertol 2021-07-06 13:26:28 +02:00
parent 54b389fd1a
commit 8ace291b32
2 changed files with 9 additions and 0 deletions

View file

@ -951,3 +951,11 @@ fn test_conflict_check_out() {
);
}
}
#[test]
fn test_key_takes_one_arg() {
new_ucmd!()
.args(&["-k", "2.3", "keys_open_ended.txt"])
.succeeds()
.stdout_is_fixture("keys_open_ended.expected");
}