[TxMt] RegEx Tool

Eric Hsu erichsu at math.sfsu.edu
Sun Apr 3 03:22:22 UTC 2005


At 6:37 PM -0500 4/2/05, John Lianogou wrote:
>Though I could see some sort of RE Unit Testing solution to be 
>potentially useful... something to keep a collection of test strings 
>to be used against an expression. Find something along the way that 
>breaks it, but shouldn't: add it to the regexp's test list!

I would personally prefer a little feature in TM to 'test' a regexp 
in a particular document. You'd write it and then (either in 
real-time or not) it would colorize the different pieces that it 
found on the screen.

My usual workflow when using regexp find/replace is:

1. Write regexp search/replace.
2. Run it and watch it do something really weird.
3. Run it in find mode and see the first thing it matches.
4. Go to 1.
5. ???
6. Profit!

It would be pretty straightforward to write a regexp tester in TM 
that would take a regexp and color highlight each of the found 
groupings in different colors in an HTML version of the document. I 
might do that for myself, now that I think of it, unless someone 
beats me to it.

best, Eric
-- 
Eric Hsu, Assistant Professor of Mathematics
San Francisco State University
erichsu at math.sfsu.edu
http://math.sfsu.edu/hsu



More information about the textmate mailing list