[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sort and multiple -k options

From: Andreas Schwab
Subject: Re: sort and multiple -k options
Date: Sun, 28 Jun 2009 10:28:38 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.95 (gnu/linux)

Mike Frysinger <address@hidden> writes:

> i want to have the files sorted by (1) path then (2) file name then (3) cfg 
> order.  so i use this:
> sort -t% -k2 -k4 -k3

Your sort keys overlap.  A sort key that is a proper subset of another
one never changes the resulting sort order, and is thus effectively

  -k, --key=POS1[,POS2]     start a key at POS1 (origin 1), end it at POS2
                            (default end of line)


Andreas Schwab, address@hidden
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

reply via email to

[Prev in Thread] Current Thread [Next in Thread]