use IPC::Run::Simple; run("some", "command") or die "command failed"; # better done as use IPC::Run::Simple qw(:all); run("some", "command") or die "badness! $ERR"; #### use IPC::Run::Simple qw(:Fatal); my $exit_value = run(command => [ "some", "command" ], allowed => [ 0, 1, 5 ]); #### use IPC::Run::Simple qw(:Fatal); my $exit_value = run(command => "some_command", allowed => [ 0, 1, 5 ]);