in reply to Getting Data::Dumper target from STDIN
One alternate (using Dumper omitted, because how to do so is not the root of OP's problem):
>perl -E "while (<STDIN>) {say shift; push @input, $_;} say @input;" foo bar baz bat sit sat sot ^Z foo bar baz bat sit sat sot
Another way, with slight (and adaptable) variation on OP's spec:
C:>perl -E "use Data::Dumper; say Dumper @ARGV;" foo bar baz bat $VAR1 = 'foo'; $VAR2 = 'bar'; $VAR3 = 'baz'; $VAR4 = 'bat';
|
|---|