【问题标题】:In Sublime Text 3, how to have shortcuts for "Build and Run" and "Build only" separately like it was in Sublime Text 2?在 Sublime Text 3 中,如何像在 Sublime Text 2 中一样分别设置“构建并运行”和“仅构建”的快捷方式?
【发布时间】:2016-05-29 02:45:47
【问题描述】:
在 Sublime Text 3 中,当我们按下 Ctrl+Shift+B 时,我们可以选择执行“构建并运行”或“仅构建”,而 Ctrl+B 执行之前选择的两个操作。但我希望它是这样的,它应该在我按 Ctrl+Shift+B 时直接构建和运行,并且只有在我按 Ctrl+B 时才构建,就像在 Sublime Text 2 中一样。有人可以帮我吗?
【问题讨论】:
标签:
sublimetext2
keyboard-shortcuts
sublimetext3
sublimetext
shortcuts
【解决方案1】:
将此添加到您的 sublime-keymap 应该会产生预期的行为:
{ "keys": ["ctrl+b"], "command": "build", "args": { "variant": "" } },
{ "keys": ["ctrl+shift+b"], "command": "build", "args": { "variant": "Run" } },
但是您可能想要重新映射保留选项列表到 alt+b:
{ "keys": ["alt+b"], "command": "build", "args": { "select": true } },
【解决方案2】:
不回答问题但很高兴知道,F7 功能与 Ctrl+b 相同。