On 05/11/2021 09:31 am, Yang Yanchao wrote:
Dear Coreutils Maintainers,



When I sort the use cases using "sort":

[root@localhost test]# cat test

1.2.v1.6

1.0.v3.5

1.10.v2.4

[root@localhost test]# sort -n -t'.' -k3,3 -k4,4 test

1.10.v2.4

1.0.v3.5

1.2.v1.6



The order I expected should be like this.

1.2.v1.6

1.10.v2.4

1.0.v3.5



It looks like the third column is alphabetic, and I added the -n option, which 
was ignored, but I used -k to specify the third column as the first 
priority.This means that -k has a lower priority than -n? Does this fit the 
intended design?



Thanks,

Yang Yanchao


Try -V instead of -n

--
Chris Elvidge
England


Reply via email to