in reply to Backtics execution with multiple lines

You can also use a HEREDOC but interpolation still occurs so the backslash needs escaping.

$ cat > testfile line 1 line 2 line 3 line 4 line 5 $ perl -e ' > $result = <<`EOC`; > tail -2 \\ > testfile > EOC > print $result;' line 4 line 5 $

I hope this is of interest.

Cheers,

JohnGG