From owner-freebsd-questions Thu Aug 13 13:11:36 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id NAA03539 for freebsd-questions-outgoing; Thu, 13 Aug 1998 13:11:36 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from resnet.uoregon.edu (resnet.uoregon.edu [128.223.144.32]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id NAA03526 for ; Thu, 13 Aug 1998 13:11:34 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Received: from localhost (dwhite@localhost) by resnet.uoregon.edu (8.8.5/8.8.8) with SMTP id NAA26721; Thu, 13 Aug 1998 13:11:01 -0700 (PDT) (envelope-from dwhite@resnet.uoregon.edu) Date: Thu, 13 Aug 1998 13:11:00 -0700 (PDT) From: Doug White To: Roman Katsnelson cc: "q's" Subject: Re: Cron daemon question In-Reply-To: <35D1FCD8.AA09BFEF@graphnet.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 12 Aug 1998, Roman Katsnelson wrote: > I have a little piece of code sitting in /usr/local/bin/stuff > directory... This code involves something like this, for example: > > cd morestuff #should now be in /usr/local/bin/stuff/morestuff > > do whatever, then exit > > When I run it command line, it works. > I made a crontab that calls it, and the cron daemon mailed me this: > > cd: morestuff: No such file or directory > > The crontab calls the code as /usr/local/bin/stuff/code.sh > > Should I change the code to make it do absolute paths? I'd rather not, > if there were a way around it, but if that's one of the crontab > requirements then I guess I will... Use absolute paths. Cron's starting directory is undefined. Doug White | University of Oregon Internet: dwhite@resnet.uoregon.edu | Residence Networking Assistant http://gladstone.uoregon.edu/~dwhite | Computer Science Major To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message