visual-studio-code - VScode定义自定义快捷方式重新启动并运行所有
问题描述
我最近一直在为我的笔记本使用 VS Code。但是,我真的很怀念香草 Jupyter 笔记本中提供的“重新启动并运行所有”快捷方式。我在设置中找到了重启选项。
我还找到了 run-all 选项。
有没有办法可以将这两个触发器合并为一个?
解决方案
有一个叫做 vscode 的扩展程序multi-command
可以让你做到这一点。转到您的扩展程序,找到扩展程序并安装它。完成此操作后,转到您的键绑定并打开keybindings.json
,您可以通过单击此处进行操作(附图片)。
然后继续添加以下内容:
{
"key": "oem_8", //put whatever key you want here
"command": "extension.multiCommand.execute",
"args": {
"sequence": [ //put whatever keybind actions you want in here
"jupyter.notebookeditor.restartkernel",
"notebook.execute"
]
},
"when": "editorTextFocus"
}
我希望我有所帮助!
推荐阅读
- html - 引导轮播不滚动错误
- python - 使用 seaborn 和 matplotlib.pyplot 在 python 中处理 Xticks
- r - R highcharts 图表上的特定颜色列
- firebase - 搜索功能流重构
- sql - ORA-06502: PL/SQL: 数字或值错误: 字符串缓冲区太小: 构建模型时
- c - 使用公式计算C中long的范围
- javascript - 我怎样才能使 vanilla js 动态背景平滑?
- python - 在我添加一定数量的实体后,用于 Python 的 Ursina 游戏引擎不允许我全屏显示游戏
- hibernate - 休眠一对一映射,如何不插入孩子但绑定到它
- c# - 当 UTC 与时区偏移一起使用时,DateTime.Parse 方法中是否存在错误?