Re: [opensuse] Another grep question
- From: Anders Johansson <andjoh@xxxxxxxxxx>
- Date: Sun, 8 Apr 2007 23:15:43 +0200
On Sunday 08 April 2007 20:49:02 James Hatridge wrote:
Hi all,,
I'm not sure if this is a grep or awk question. I have a file with many
records of 4 lines each in it. Like this:
1
2
3
4
1
2
3
4
etc, etc
I need the file to look like this:
1 tab 2 tab 3 tab 4
1 tab 2 tab 3 tab 4
etc etc....
How can I do this?
Perhaps with bash?
#!/bin/bash
while read line1; do
read line2;
read line3;
read line4;
echo -e "$line1\t$line2\t$line3\t$line4" >> outputfile
done < testfile
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
- References:
- [opensuse] Another grep question
- From: James Hatridge
- [opensuse] Another grep question
- Prev by Date: Re: [opensuse] Another grep question
- Next by Date: [opensuse] deleting clamav preferences
- Previous by thread: Re: [opensuse] Another grep question
- Next by thread: Re: [opensuse] Another grep question
- Index(es):
Relevant Pages
|