[TxMt] "Scope" within a .tm_properties file?

Charles Turner vze26m98 at gmail.com
Sun Jan 1 13:59:25 UTC 2012


Happy New Year everyone-

I know "scope" probably isn't the right word here, but this is what
I'm struggling with:

I work with a fellow who uses TextWrangler, and for a bunch of legacy
reasons, has language files (Forth) that have no extension to indicate
their contents. I'd love to be able to open these and have them
automatically be parsed as Forth source. This is an obvious solution
for a folder:

[ "cocoa/*" ]
fileType = "source.forth"

But some folders also have other file types in them with extensions:
.txt, .prf ,etc.

So it'd be great to say something like this:

[ "cocoa/*" ]
fileType = "source.forth"

["cocoa/*.{txt, prf}"]
fileType = "text.plain"

and have any text or preferences file be treated as text, and anything
else be considered a Forth source file.

Is this the way that TM2 works? Or are all specifications assumed to
be mutually exclusive?

(And if they are expected to be mutually exclusive, how are glob
conflicts handled?)

Thanks! Charles


More information about the textmate mailing list