open my $PIPE, '-|', 'diff', $file1, $file2 or die "Cannot open pipe f +rom 'diff' $!"; my @diffs = map { s/^[><]//; $_ } <$PIPE>; close $PIPE or warn $! ? "Error closing 'diff' pipe: $!" : "Exit status $? from 'diff'";
In reply to Re: using system() and putting results into an array
by jwkrahn
in thread using system() and putting results into an array
by lasagnashoe
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |