[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Bash Scripting: How to pass "yes" + carriage return?
- Subject: [ale] Bash Scripting: How to pass "yes" + carriage return?
- From: esoteric at 3times25.net (Geoffrey)
- Date: Fri, 11 Nov 2005 07:40:58 -0500
- In-reply-to: <000001c5e6ba$960ff1a0$6401a8c0@win2kpro1>
- References: <000001c5e6ba$960ff1a0$6401a8c0@win2kpro1>
Ryan Fish wrote:
> Hello all,
>
>
>
> I am in need of figuring out how to pass a "yes" followed by a carriage
> return via a bash script so a backup process can run successfully each day.
>
>
>
> The script does the following:
>
>
>
> 1) ssh to RaQ server as root
>
> 2) run cmuExport
>
> 3) copies contents of export to NAS device
>
>
>
> Since cmuExport has been run before a prompt stating the directory the file
> is written to already exists, do I want to overwrite is returned. The only
> way to get past this point is to enter "y" then press ENTER at the prompt.
> This is what I am attempting to automate.
>
>
>
> Thank you for any help offered!
have you tried:
echo "y" | cmuExport
--
Until later, Geoffrey