Sublime text: How to disable automatching 'quotes'

Viewed 1074

Here's my problem: In common lisp, a 'single quote' is not used for strings and thus doesn't come in pairs with another quote, so sublime text auto-inserting another quote does more harm than good. How do I disable that option just for lisp and just for single quotes?

2 Answers

Just add a keybinding to your keymap (which you can find in preferences, key bindings) and in the user tab paste this:

{
  "keys": ["'"], "command": "insert", "args": {"characters": "'"},
  "context":
  [
    { "key": "selector", "operator": "equal", "operand": "source.lisp" }
  ]
},

Let me know if you need anything else! I tested it in sublime text (I use it too)

If you go into Preferences > Settings on Sublime Text 3, you should see various preferences that you can control manually. This line controls the auto-pairing of quotes:

// Controls auto pairing of quotes, brackets etc
"auto_match_enabled": true,

To overwrite it, add "auto_match_enabled": false, to the right pane (user prefs) between the brackets and save to update your preferences. If you already have preferences in the right pane, be sure to separate with a ',' like with json properties.

Related