Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 20 Aug 2002 10:59:17 -0400
From:      "MET" <met@uberstats.com>
To:        "'freebsd-questions-en'" <freebsd-questions@FreeBSD.ORG>
Subject:   Auto Answering a Command Prompt || Not best the best phrase
Message-ID:  <001d01c2485a$28fc8710$6901a8c0@SURVIVAL>

next in thread | raw e-mail | index | archive | help
The host I'm using has a little built in system to auto ask the user (no
matter what) if they want to overwrite (y/n) the file they're trying to
save or archive/compress in this case.  So every time I run my script is
asks me a question.  I need the script to run as a Cronjob at a
ridiculous time in the morning by itself.  So I'm trying to force the
'yes' down its throat, but I don't know how.  Here's my current
compression line:

DATE=`date +%m-%d-%Y`;
ARCHIVED="Gunks_Ads-$DATE.tar.bz2";
tar cjf ../backups/$ARCHIVED ../backups/Gunks_Ads.txt;

So...how do I stuff a 'yes' down its throat after the last command
above?


~ Matthew


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?001d01c2485a$28fc8710$6901a8c0>