Re: script to write to standard input ?
- From: Dan Espen <daneNO@xxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 19 Dec 2005 20:18:37 -0500
"pc" <chalk@xxxxxxxxxxxxxxx> writes:
> hi all,
>
> I have a script that I want to send some standard input to (eg simulate
> the user typing 'a' - ENTER ). If I try echo a | myscript, I receive an
> error: option:stty: : Not a typewriter
>
> This is running in ksh.
This depends on your script. For example:
Given x.sh:
#!/bin/ksh
read ans
echo "answer is $ans"
I get:
echo "aa" | ./x.ksh
answer is aa
Maybe the script shouldn't be fooling with the stty command.
.
- Follow-Ups:
- Re: script to write to standard input ?
- From: Enrique Perez-Terron
- Re: script to write to standard input ?
- References:
- script to write to standard input ?
- From: pc
- script to write to standard input ?
- Prev by Date: Re: Bash script piping question
- Next by Date: Re: Advantages of 64-bit Installation?
- Previous by thread: script to write to standard input ?
- Next by thread: Re: script to write to standard input ?
- Index(es):
Relevant Pages
|