in reply to Re: replace text using hash
in thread replace text using hash

> One feature of LanX's solution that was not mentioned

true, I was too lazy to type more... ;-)

> you'd probably need to slurp the file

I think paragraphs should be enough. And either the /s or /m modifier should help with newline as whitespace. (still need a mnemonic but I think it was /m /s because it was counter-intuitive)

update

seems like \s already matches newline as whitespace. The /s modifier only effects the match-all-dot . to match newlines.

So replacing all whitespaces in the keys with \s+ should be sufficient.

Cheers Rolf

(addicted to the Perl Programming Language and ☆☆☆☆ :)