Skip to content

Instantly share code, notes, and snippets.

@sligodave
Last active December 23, 2015 00:28
Show Gist options
  • Select an option

  • Save sligodave/6553396 to your computer and use it in GitHub Desktop.

Select an option

Save sligodave/6553396 to your computer and use it in GitHub Desktop.
A simple sublime text plugin to change the syntax of every opened or new file to YAML. Drop the file "SyntaxToYAML.py" into your Sublime Text "Packages/User/" directory. Add the keymaps to the files with the same name in your "Packages/User/" directory too. DON'T overwrite the "Default (XXX).sublime-keymap" files that are already there. Add to t…
import sublime_plugin
class SyntaxToYAMLEventListener(sublime_plugin.EventListener):
def on_load(self, view):
view.set_syntax_file('Packages/YAML/YAML.tmLanguage')
on_new = on_load
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment