Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Reading a file line by line
Name: Mona Date: September 30, 2003 at 13:13:52 Pacific OS: Sun OS CPU/Ram: 240
Comment:
Hi,
I wrote the following code to read a file line by line #!/bin/ksh for i in `cat a.txt` do echo $i done
This is not showing me the file contents line bye line. Instead I am seeing a word by word output. What is wrong ? DO I need to format the text file in some way that it reads the end of line char ?
Summary: Hi, I am trying to read a file which has two fields i.e tab seperated. Each line has an OldImage Name and a NewImage Name. Can anyone help me to write a shell script which reads the file and changes t...