Help for this page
open my $FH, '>', 'afile.pl'; print $FH <<EOHDR; ... elsif (/^FOO/) { print $FH, "something completely different" } elsif (/^Q/) { last; } }
my $SCRIPT = <<EOHDR Some header stuff EOHDR; $SCRIPT .= "More script stuff";