[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: sort feature requests
From: |
Jim Meyering |
Subject: |
Re: sort feature requests |
Date: |
Mon, 30 Jul 2007 21:49:51 +0200 |
Matthew Woehlke <address@hidden> wrote:
> This should already be possible with a command such as:
> $ ( sed 1q ; sort [args] ) < [file]
>
> ...however it seems my version of sed (4.1.2-RH4) does not honor POSIX
> semantics and consumes too much of the input ('head' from
> coreutils-6.9 seems to have the same problem?) I did get 'read 4 ;
> echo $a' to work however.
>
> (Ok gnulib folks, I don't have any dates handy, is the fseek stuff
> newer than coreutils-6.9?)
Using head works for me, both with coreutils-5.97
and the very latest 6.9+:
$ (echo 5; seq 3) > k; (head -1; sort -n) < k
5
1
2
3
If you're reporting a bug, please be specific.