LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Johnny can't read (https://www.linuxquestions.org/questions/programming-9/johnny-can%27t-read-13748/)

WindozBytes 02-07-2002 11:33 AM

Johnny can't read
 
I'm running a Korn shell script and want to read the first line from an external file into a local variable within the shell. I'm thinking that 'READ' would be the simplest way to do this, but I can't seem to find the syntax to read only a single line from a file.

Any help would be appreciated.

TIA

WindozBytes 02-07-2002 12:37 PM

nevermind
 
I was trying to make this far too difficult; it's just:

READ LocalVariable < ExternalFile


All times are GMT -5. The time now is 03:08 AM.