i am trying to convince the perl bundle to properly fold pod documents. has anyone tried this with success?
i have tried modifying the Start/Stop markers from
foldingStartMarker = '(/*|({|[|()\s*$)'; foldingStopMarker = '(*/|^\s*(}|]|)))';
to foldingStartMarker = '(/*|({|[|()\s*$|^=head\d)'; foldingStopMarker = '(*/|^\s*(}|]|))|^=cut)';
which works fine for a simple block:
=head1 HELLO
Hello, World.
=cut
but not for blocks that have more than one =head marker:
=head1 HELLO
Hello, World.
=head2 OOPS
Now head1 and head2 both show folding carets, but only the one one by head2 does anything when you click it.
=cut
i tried to get clever and use perlish zero-width positive look-ahead regex -- something like (^=head\d(.|\n)*(?==cut)) -- but textmate doesn't appear to support such patterns.
any suggestions?