atombender / sublime_text_alternative_autocompletion

Adds TextMate-like autocompletion to Sublime Text 2 and 3.
MIT License
147 stars 23 forks source link

Keybinding sample for tab parse error #14

Closed papz closed 12 years ago

papz commented 12 years ago

Perhaps this is known, but it's helpful to provide an accurate keymap.

Sublime Version 2.0, Build: 2210 produces parse error when saving the tab binding.

Error trying to parse file: Trailing comma before closing bracket in ~/Library/Application Support/Sublime Text 2/Packages/User/Default (OSX).sublime-keymap:34:3

Removing a few commas does the trick.
{ "keys": ["tab"], "command": "alternative_autocomplete", "args": {"default": "\t"}, "context": [ { "key": "num_selections", "operator": "equal", "operand": 1 } ] }, { "keys": ["shift+tab"], "command": "alternative_autocomplete", "args": {"cycle": "previous"}, "context": [ { "key": "num_selections", "operator": "equal", "operand": 1 } ] }, { "keys": ["tab"], "command": "indent", "context": [ { "key": "text", "operator": "regex_contains", "operand": "\n" } ] }, { "keys": ["shift+tab"], "command": "unindent", "context": [ { "key": "text", "operator": "regex_contains", "operand": "\n" } ] }