bug-coreutils
[Top][All Lists]
Advanced

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

Re: reversing the order in which lines appear


From: Pádraig Brady
Subject: Re: reversing the order in which lines appear
Date: Fri, 25 Jan 2008 15:59:03 +0000
User-agent: Thunderbird 2.0.0.6 (X11/20071008)

Francky Leyn wrote:
> Hello,
> 
> I'm seeking for some way to revert the order of lines. The first line
> read thus must get out last and the last read must be output first.
> 
> Although it's easy to write a program for it, I'm wondering if this
> is not possible with the UNIX toolbox. Any ideas?
> 
> I first tought of something like "cat -r", where the r stand for reverse.
> Is this a good suggestion, or a bad one?

I bet you'll laugh :)

`tac` is the command you want.

In general this sort of question is well answered by `apropos reverse`

thanks,
Pádraig.




reply via email to

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