I'm trying to create a simple colorization for log files, now that it's possible include custom languages in Code (I'm on 0.9.2). I have created a simple .tmLanguage file for colorizing the letter 'q', just for starting up, but have been unsuccessful.
My new language, log
, is associated correctly with the file extension and I can also select it manually from inside Code, but no coloring takes places. I have a feeling it has to do with what "scope" I associate my pattern with, but I'm not sure. Is there a list of valid scope to choose from? Initially I thought I'd use something general, such as "comment" to get some color, but it doesn't seem to work.
Here's my .tmLanguage file:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>scopeName</key>
<string>text.log</string>
<key>fileTypes</key>
<array>
<string>log</string>
</array>
<key>name</key>
<string>Log file</string>
<key>patterns</key>
<array>
<dict>
<key>match</key>
<string>q</string>
<key>name</key>
<string>comment</string>
</dict>
</array>
</dict>
</plist>
I'm probably misunderstanding something here, so any help is very appreciated :-)