# Having Trouble Matching A Blank Line In TextMate Bundle Editor

**URL:** <https://www.ruby-forum.com/t/having-trouble-matching-a-blank-line-in-textmate-bundle-editor/147982>\
**Category:** Rails\
**Created:** [September 8, 2008, 2:17am UTC](https://www.ruby-forum.com/t/having-trouble-matching-a-blank-line-in-textmate-bundle-editor/147982 "2008-09-08T02:17:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wyatt\_G](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/53a042/32.png) [@Wyatt\_G](https://www.ruby-forum.com/u/Wyatt_G)\
**Post date:** [September 8, 2008, 2:17am UTC](https://www.ruby-forum.com/t/having-trouble-matching-a-blank-line-in-textmate-bundle-editor/147982/1 "2008-09-08T02:17:47Z")

</div>

I couldn’t find the Ruby on Rails: TextMate group (did it go away?) so  
I’m posting my question here.

I’m creating my own custom language syntax for TextMate. In the  
bundle editor I’m setting up folding like this:

foldingStartMarker = ‘^\S+._$’;  
foldingStopMarker = '^\s_$’;

This tells TextMate that the start of a foldable section is any non-  
empty line that isn’t indented, and the end of a foldable section is  
an empty line.

I’m trying to match the case where the line is not technically empty,  
but only contains whitespace (hence the \s\* part of the regular  
expression). This does not work. The folding stop marker appears  
when the line is completely empty, but the moment I put spaces in the  
line, the folding stop marker goes away.

Did I get the regular expressions wrong, is it a bug in TextMate, or  
is something else wrong?

Thanks in advance!  
Wyatt
