I need to write a Perl script to read in a file, and delete anything inside < >, even if they're on different lines. That is, if the input is:
Hello, world. I <enjoy eating bagels. They are quite tasty.I prefer when I ate a bagel to when I >ate a sandwich. bananas.
I want the output to be:
Hello, world. I ate a sandwich. bananas.
I know how to do this if the text is on 1 line with a regex. But I don't know how to do it with multiple lines. Ultimately I need to be able to conditionally delete parts of a template so I can generate parametrized files for config files. I thought perl would be a good language but I am still getting the hang of it.