9

In Sublime Text 3,when we press Ctrl+Shift+B, we are given the option to either do "Build and Run" or "only Build", whereas Ctrl+B executes the previously chosen operation among the two. But I want it to be like, it should directly build and run when I press Ctrl+Shift+B and only build when I press Ctrl+B like it was in Sublime Text 2. Can someone help me out?

spharish
  • 275
  • 1
  • 2
  • 11

2 Answers2

11

Addings this to your sublime-keymap should result in the expected behavior:

{ "keys": ["ctrl+b"], "command": "build", "args": { "variant": "" } },
{ "keys": ["ctrl+shift+b"], "command": "build", "args": { "variant": "Run" } },

However you might want to remap keep the list of options to alt+b:

{ "keys": ["alt+b"], "command": "build", "args": { "select": true } },
r-stein
  • 4,627
  • 2
  • 16
  • 27
1

Not answering the question but good to know, F7 functions the same as Ctrl+b.

enter image description here

Mark K
  • 8,767
  • 14
  • 58
  • 118