First off, what a bizarre problem to be solving. Are you certain you're solving the correct problem?
Secondly, what's happening is that you're sending the contents of $os_says to perl's eval.
The code you have currently is equivalent to:
$os_says .= `$_`;
eval($os_says);
What you want to do right now (as was already pointed out) is switch to:
eval { $os_says .= `$_` };
However, once you do that, you'll have the case that $@ will always be the null string, no matter if the backquoted command failed or not.(*) If you want to check on the return status of the executed command, check $!.
But let me repeat - I do not think you are doing what you want to do. First off, you're executing every line with /bin/sh, and not with /bin/csh, even if csh is your default shell. Secondly, each line is getting executed in its own subprocess, so even if you were executing the lines with csh, this two line combination would produce an "Undefined variable" error:
setenv ADP_INPUT_HOME /disk4/vendor/adp/
echo "Looking for files in $ADP_INPUT_HOME"
Now, it would be possible to open a csh shell in the background and feed it one line at a time, and I suppose you could monitor the csh shell to see if it exited, but that's a much, much more advanced problem than you seem to be aiming for here.
Why on earth are you trying to do this?
(*) Okay, so I think $@ might contain something if the system were so overloaded that a subprocess couldn't be forked to do the backquote magic.
--
@/=map{[/./g]}qw/.h_nJ Xapou cets krht ele_ r_ra/;
map{y/X_/\n /;print}map{pop@$_}@/for@/
|