In this example we treat the return code of "echo" which is always 0 of course. But ist will also work when you remove the echoing and execute the perlscript instead.#!/usr/bin/sh echo /usr/bin/perl perlscript.pl ret=$? echo "Status String is $?" if [ $ret -eq 0 ] then echo "case A" else echo "case B" fi echo going to exit shell with $ret exit $ret
In reply to Re: Re: Re: Re: Re: calling perl script from shell script
by pelagic
in thread calling perl script from shell script
by shilpam
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |