in reply to Replace strings in text file

open my $lookup, '<', $lookuptxtfile or die $!; open my $new_lookup, '>', "$" or die $!; while (<$lookup>) { s/The action failed./failed_build/g; print {$new_lookup} $_; } close $new_lookup; rename "$", $lookuptxtfile or die $!;

Creating a new file and renaming it is what sed does behind the scenes, anyway.

Are you sure you don't want to backslash the dot?

($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,