bug-gnu-emacs
[Top][All Lists]
Advanced

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

Re: but what if the items they wanted to sort were all on one line?


From: David Kastrup
Subject: Re: but what if the items they wanted to sort were all on one line?
Date: 23 Feb 2002 10:11:55 +0100
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2.50

address@hidden (Dan Jacobson) writes:

> Of all the sorting commands listed in Info: sort-lines, etc. the
> likelihood is big one day that a user will come with a line to sort like
> 2 7 8 12 21 23 15 29 30 36 38.
> I mean you have several functions ready for users with data in one
> item per line formats, but none to sort many items on the same
> line---an indeed common thing one might want to do.  Perhaps one at
> least could add one solution to the Docs, e.g.
> 
> $ echo 2 7 8 12 21 23 15 29 30 36 38|tr \  \\n|sort -n|tr \\n \ 
> 2 7 8 12 15 21 23 29 30 36 38 0

Fill the region with a line width of 1 character, sort, then fill the
region with a line width of point-max.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum
Email: address@hidden



reply via email to

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