you can use the exit function like so: <snip> #!/usr/bin/perl -wT
blah......; if (it worked){ exit(0); } else { exit(100); } </snip> On Wed, Oct 22, 2003 at 10:41:15AM -0500, Jason wrote: > Hi All, > > I need to write a script that cooperates with a bunch of other scripts > in the 'toolbox' paradigm which is often thought of as a core tenet of > UNIX philosophy. In particular, when my script fails, the other > scripts will look in $? and based on the number therein they will > perform some actions. However, I don't know how to write to $? and so > I may have to rewrite a whole bunch of scripts to read from STDERR. > Not something I am looking forward to. How to a send a value to $? in > Perl? I have tried the return function but that only works in > subroutines . . . > > Thanks in Advance, > Jason Dusek > > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- Mat Harrison | email: [EMAIL PROTECTED] 3d Computer Systems Ltd. | tel: ++441249 460 766 11 New Road | fax: ++441249 460 583 Chippenham | gpgid: 0x9FE38627 Wiltshire SN13 9RW England
pgp00000.pgp
Description: PGP signature