As a one-liner:
c:\test>perl -ple"s[^(.*)$]{ $1 =~ m[DOG] ? 'DOG' : 'Not found' }e" ju +nk.dat DOG DOG Not found DOG Not found DOG DOG DOG DOG
In reply to Re: Replacing a search/not found pattern with a word
by BrowserUk
in thread Replacing a search/not found pattern with a word
by pinpe
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |