I have created a new Build System to run GolfScript programs. The definition is the following:
{
"cmd": ["ruby", "D:\\w\\sublime\\golfscript.rb", "$file"]
}
This works, but I have to manually switch the Build System from "Automatic" to "golfscript" whenever I need to use this and then switch it back to be able to run Ruby, Python, etc.
I'd like to make my Build System be automatically applied when I have a *.gs
file open.
I have read some docs and got the idea that I can use a selector in order to achieve this, so I added a selector to the existing configuration:
{
"cmd": ["ruby", "D:\\w\\sublime\\golfscript.rb", "$file"],
"selector": "source.gs"
}
After reading even more docs/examples, I could not figure out how to tell sublime what the selector is actually about.
How can I configure the source.gs
selector to point to *.gs
files?