[TxMt] Re: Conditional regex

Dijk van Marc marcvdijk at gmail.com
Fri May 29 21:57:58 UTC 2009


> {	name = 'meta.test';
> 	match = '^(ATOM|HETATM).*(GLN)';
> 	captures = {
> 		1 = { name = 'keyword.first-match'; };
> 		2 = { name = 'string.second-match'; };
> 	};
> }
>
> This should color each match differently. Please note that there are
> many different ways to do this and may not be the best way for your
> needs.
>
> Do yourself a favor and look up some regex tutorials on the web. They
> will help immensely.
>
> --oliver


        captures = {
		1 = { name = 'keyword.first-match'; };
		2 = { name = 'string.second-match'; };
	};

That was the missing link I was looking for.
Thanks Oliver.

Marc



More information about the textmate mailing list