in reply to simultanious system calls on windows

I have checked out a bunch of things but none seem straight forward

What bunch?

use Proc::Background

  • Comment on Re: simultanious system calls on windows

Replies are listed 'Best First'.
Re^2: simultanious system calls on windows
by Anonymous Monk on Sep 11, 2012 at 19:47 UTC
    #!/usr/bin/perl -- use strict; use warnings; use Proc::Background; my @commands = ( [ 'echo', 'arg','arg', ] , [ 'perl', '-le',' print 1; sleep 1; warn 2; sleep 1; die 3;' ], ); my @procs = map { Proc::Background->new(@$_); } @commands; $_->wait for @procs; system 'echo', 'nowTheyAreAllDead.pl', '--pidsAndExitStatus', map { $_ +->pid, $_->wait } @procs; __END__ arg arg 1 2 at -e line 1. 3 at -e line 1. nowTheyAreAllDead.pl --pidsAndExitStatus 2956 0 2120 65280