Keyboard redirection in csh shell script

Keyboard redirection in csh shell script

Post by John » Sun, 21 Nov 1999 04:00:00



I am trying to capture keyboard input from a shell script. I am using

set temp= $<

However this only catches the first word. However I want to capture the
complete sentence typed in up until the carriage return.

e.g If I typed "The cat sat on the mat"<RET>

temp would contain only "The".

I know I can do it in Ksh with the read function but the complete script is
in csh. Any one know the equivalent in csh.

Thanks in advance.

John C

 
 
 

Keyboard redirection in csh shell script

Post by Eric Amic » Sun, 21 Nov 1999 04:00:00



> I am trying to capture keyboard input from a shell script. I am using
> set temp= $<
> However this only catches the first word. However I want to capture the
> complete sentence typed in up until the carriage return.

set temp="$<"

--
Eric Amick
Columbia, MD