$Cmd = "$HOME/bin/P2.pl"; die print "\n\n-E- Files: '$Cmd does not exist.\n" if (-e $Cmd); print "\n-I- Executing:\n\t$Cmd\n"; $status = system ($Cmd); if ($status) { my $errMsg = "-E- Failed to execute:\n\t$Cmd "; print "\n\n$errMsg\n"; killBuild ("$errMsg"); exit 1; } else { print "\n-I- Script:\n\t'$Cmd\n Completed successfully.\n"; }