PDA

View Full Version : remove first line from file


monkeyking
March 28th, 2007, 02:08 PM
Is there some nice linux tool for removing the first line of a file?

thanks in advance

Ragazzo
March 28th, 2007, 02:15 PM
One way: sed 1d file > newfile

monkeyking
March 28th, 2007, 02:16 PM
hehe thanks for the quick reply

<mawe>
March 28th, 2007, 02:40 PM
Another way: tail +2 file > newfile

rumli
December 30th, 2008, 02:30 PM
Another way: tail +2 file > newfile

I think it should be tail -n +2 file > newfile