Date: Fri, 16 Oct 2009 13:58:52 +0100 From: krad <kraduk@googlemail.com> To: Paul Halliday <paul.halliday@gmail.com> Cc: questions@freebsd.org Subject: Re: export PATH in script called via Cron. Message-ID: <d36406630910160558p78c15342qc94952d91c14630d@mail.gmail.com> In-Reply-To: <2dab70a30910160525q3f30a170ufb54277ae484e016@mail.gmail.com> References: <2dab70a30910160525q3f30a170ufb54277ae484e016@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
2009/10/16 Paul Halliday <paul.halliday@gmail.com> > I have a script that I call via Cron. > > It wont work unless I include a path: > > #!/usr/local/bin/bash > PATH="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/usr/local/sbin" > export $PATH > > which is fine and works. Out of curiosity though, why is it that if I > call it from the cl like ./test.sh I get this error: > > ./test.sh: line 3: export: > `/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/usr/local/sbin': not a > valid identifier > > The script still works but it does drop that error. > > What does it mean? > > Thanks. > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to " > freebsd-questions-unsubscribe@freebsd.org" > drop the $ in front of path in the export line
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?d36406630910160558p78c15342qc94952d91c14630d>