|
From: | Pádraig Brady |
Subject: | Re: [sort] Suggestion: count keys from the end of record |
Date: | Sun, 13 Aug 2023 16:09:52 +0100 |
User-agent: | Mozilla Thunderbird |
On 13/08/2023 15:40, Renaud Pacalet wrote:
I am a bit surprised that it has never been suggested before but I could not find any trace of it, so here it is: Would it be possible to specify the sorting keys from the end of the record, instead of the beginning. Something like sort -k-1,-1 to sort on the last field of each record, sort -k-2,-2 for the second to last... This would be handy when the format has a variable number of fields per record but the last records are well defined.
I vaguely remember this being suggested before ... https://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00008.html The interface and functionality does make sense. The only question I have is if it is functionality that is needed often enough. cheers, Pádraig
[Prev in Thread] | Current Thread | [Next in Thread] |