I use the app Oyster on Mac to edit and debug regexs. It works nicely, but doesn’t properly predict what TextMate will do with a regex. Something that works in Oyster, does not in TextMate.
Has anyone using Mac found a regex editor that predicts TextMate?
Bob ------------------- Robert J. Rockefeller Richmond Hill, GA www.bobrockefeller.com http://www.bobrockefeller.com/
On Feb 8, 2015, at 2:02 PM, Bob Rockefeller bob@bobrockefeller.com wrote:
I use the app Oyster on Mac to edit and debug regexs. It works nicely, but doesn’t properly predict what TextMate will do with a regex. Something that works in Oyster, does not in TextMate.
Has anyone using Mac found a regex editor that predicts TextMate?
TextMate uses Oniguruma. So does Ruby, so any Ruby regex tester will apply. I like http://rubular.com. m.
-- matt neuburg, phd = http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Programming iOS 8! http://shop.oreilly.com/product/0636920034261.do iOS 7 Fundamentals! http://shop.oreilly.com/product/0636920032465.do RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html
Thanks!
And Oyster does Ruby regex, too. So I’m good. Except that what Oyster shows working still does not work in TextMate. :(
This regex:
[`]{3}[\s\S]*?[`]{3}
looks to match a ``` and ``` Markdown code block in Oyster, but doesn’t in TextMate. Have I missed something else?
{ name = 'markup.raw.block.markdown'; match = '[`]{3}[\s\S]*?[`]{3}'; },
Bob ------------------- Robert J. Rockefeller Richmond Hill, GA www.bobrockefeller.com http://www.bobrockefeller.com/
On Feb 8, 2015, at 5:36 PM, Matt Neuburg matt@tidbits.com wrote:
On Feb 8, 2015, at 2:02 PM, Bob Rockefeller bob@bobrockefeller.com wrote:
I use the app Oyster on Mac to edit and debug regexs. It works nicely, but doesn’t properly predict what TextMate will do with a regex. Something that works in Oyster, does not in TextMate.
Has anyone using Mac found a regex editor that predicts TextMate?
TextMate uses Oniguruma. So does Ruby, so any Ruby regex tester will apply. I like http://rubular.com. m.
-- matt neuburg, phd = http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Programming iOS 8! http://shop.oreilly.com/product/0636920034261.do iOS 7 Fundamentals! http://shop.oreilly.com/product/0636920032465.do RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
How does it not work. You're not expecting it to work across multiple lines, are you? m.
On Feb 8, 2015, at 2:48 PM, Bob Rockefeller bob@bobrockefeller.com wrote:
Thanks!
And Oyster does Ruby regex, too. So I’m good. Except that what Oyster shows working still does not work in TextMate. :(
This regex:
[`]{3}[\s\S]*?[`]{3}
looks to match a ``` and ``` Markdown code block in Oyster, but doesn’t in TextMate. Have I missed something else?
{ name = 'markup.raw.block.markdown'; match = '[`]{3}[\s\S]*?[`]{3}'; }
Yes, sadly I was trying for multiple lines. I read about that in the docs, but didn’t get a full appreciation for the implications until I read your article: http://www.apeth.com/nonblog/stories/textmatebundle.html
That is recommended reading for anyone working on TextMate 2 grammar definitions.
On Feb 8, 2015, at 7:12 PM, Matt Neuburg matt@tidbits.com wrote:
How does it not work. You're not expecting it to work across multiple lines, are you? m.
On Feb 8, 2015, at 2:48 PM, Bob Rockefeller bob@bobrockefeller.com wrote:
Thanks!
And Oyster does Ruby regex, too. So I’m good. Except that what Oyster shows working still does not work in TextMate. :(
This regex:
[`]{3}[\s\S]*?[`]{3}
looks to match a ``` and ``` Markdown code block in Oyster, but doesn’t in TextMate. Have I missed something else?
{ name = 'markup.raw.block.markdown'; match = '[`]{3}[\s\S]*?[`]{3}'; }
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On Feb 9, 2015, at 4:51 AM, Robert J. Rockefeller bob@bobrockefeller.com wrote:
Yes, sadly I was trying for multiple lines. I read about that in the docs, but didn’t get a full appreciation for the implications until I read your article: http://www.apeth.com/nonblog/stories/textmatebundle.html
That is recommended reading for anyone working on TextMate 2 grammar definitions.
You truly took the words right out my mouth. :) That was exactly what I was leading up to. m.
-- matt neuburg, phd = http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Programming iOS 8! http://shop.oreilly.com/product/0636920034261.do iOS 7 Fundamentals! http://shop.oreilly.com/product/0636920032465.do RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html