I'm trying to create a simple creations file for use with Sahi (.sah) files. I've followed the instructions in the documentation and in this forum but for whatever reason, they do not display. I've created a file named sahi.sublime-completions (see condensed contents below) and put it in AppData/Roaming/Sublime Text 2/Packages/User/ . I open a .sah file and hit ctrl-space and none of the completions display... nor when I start typing their names.

If I save a file with extension .sah it still says 'Plain Text' at the bottom-right corner.

Your completions show if I amend the scope to "text", but I don't know if there is a way to register .sah as a "source" file (rather than plain text). I'm guessing it requires a corresponding .tmLanguage file before it's recognised.

"I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.

FYI, Sahi code is 99.9% javascript, and I'm associating ("open all with current extension as...") my .sah files the javascript syntax highlighting (which is what I want). So then is there a way to associate .sah files more formally with Javascript so that I could then add my completions and retain js syntax highlights? Or perhaps another way to accomplish the same?

To clarify, ST2 is currently applying JS syntax to .sah files I open. This is great and works as expected.

I tried changing the scope to js (eg. source.js...) but no joy. I also tried adding <string>sah</string> to the javascript.tmLanguage file... also no joy. Also tried changing the scope back to source.sah after altering the language file. Still nothing.

What am I missing?

Thanks a bunch for the help. I really want this to work! While it won't spell doom for NP++, it'll net ST2 $59

It appears you are having trouble with scope. Would you like some help? Try pressing ctrl+alt+shift+p. This should list the current scope under the cursor in the status bar. The leftmost scope is the most specific and as you move right, it gets more general. If the scope is in fact Javascript, the rightmost scope will say source.js. Furthermore, whatever that rightmost scope is is what you want to reflect in your completions file.

Scope is certainly part of it. With one of my .sah files open, ctrl+alt+shift+p displays source.js. I changed the scope of my sahi.sublime-completions file to "scope": "source.js", saved, restarted app and still nothing. My completions don't show up.