From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19030 invoked by alias); 6 Nov 2002 22:18:18 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 19023 invoked from network); 6 Nov 2002 22:18:16 -0000 Received: from unknown (HELO EXCHANGE.wincoll.ac.uk) (212.219.8.175) by sources.redhat.com with SMTP; 6 Nov 2002 22:18:16 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.0.6249.0 content-class: urn:content-classes:message Subject: RE: How to schedule scripts Date: Wed, 06 Nov 2002 14:18:00 -0000 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: From: "Gen Zhang" To: X-SW-Source: 2002-11/txt/msg00252.txt.bz2 I'd recommend using the command of bash --login -c . This way, all the paths needed by perl, mailer, etc. are set up by the .profile as it would be. You're not opening this thing load of times per minute, so the performance shouldn't matter so much. Just my two pence. Genneth > -----Original Message----- > From: Max Bowsher [mailto:maxb@ukf.net] > Sent: 05 November 2002 22:32 > To: Stan Horwitz; cygwin@cygwin.com > Subject: Re: How to schedule scripts >=20 > Stan Horwitz wrote: >=20 > > Now, I want to schedule this [perl] script to run once a day as > > Administrator. With that in mind, I created a request under Windows' > > Task scheduler, but when the scheduled time occurred, a Cygwin shell > > window opened up, but nothing else happens. The request I scheduled > > was "cygwin daily.pl; exit" but the "daily.pl" script never executes; > > nor does "exit". As such, I end up with a Window to a Cygwin shell on > > my screen. >=20 > "cygwin" is of course "cygwin.bat". If you look at it, you will see that > it > doesn't make any attempt to pass args on to the shell. > But you don't want a shell anyway. Just invoke perl directly: "perl > /full/path/to/daily.pl". Of course you will need C:\cygwin\bin, or the > equivalent on your system, in PATH (either the system-wide setting, or the > user the script will run as), so that perl can be found, and it in turn > can > find DLLs that it needs. >=20 > Max. >=20 >=20 > -- > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > Bug reporting: http://cygwin.com/bugs.html > Documentation: http://cygwin.com/docs.html > FAQ: http://cygwin.com/faq/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/