0

My question is directed related to this question. The difference is that TextMate v.2.0.6 appear to have evolved to the point where answers to that question are not helping.

Question: How to add a file association to an existing bundle?

Specifically, how to add extension ncx to the html bundle. Here's a screenshot of what I've tried. In words:

Menu -> Bundles -> Edit Bundles... -> HTML -> Language Grammars -> HTML -> 'Injection Selector': ncx -> Press '+'.

Instead of adding ncx to the list, a blank is added (see inside the red circle). And files with extension 'ncx' have no syntax highlighted.

Moreover, now file names in the top bar appear as toc.ncx -- ncx or README.md -- ncx, i.e. a mysterious --ncx has now been added at the top of the screenshot (see inside the red circle).

What have I done wrong? Thanks!

enter image description here

PatrickT
  • 103

1 Answers1

1

Double click on the empty line to change its value.

IIRC: "Injection Selector" refers to situations like a <script> tag in html, where the html grammar provides a selector, that -when matched- activates the JavaScript syntax.

It occurs to me that, while the above is (hopefully) the answer to your question there may be a better way. Instead of modifying the bundle you could/should use .tm_properties:

#~/.tm_properties
[ *.ncx ]
fileType         = 'text.html.basic'