如何将 Windows 上的 VSCode 键映射转移到 ubuntu [英] How to transfer VSCode key mapping on windows to ubuntu
问题描述
我在 Windows 上使用 vs-code 作为我的首选编辑器.最近我在 Ubuntu 上安装了,现在默认的键映射不同了.
I use vs-code as my go-to editor on Windows. Recently I've installed on Ubuntu and now the default key mapping is different.
有什么办法可以在 Ubuntu 上设置类似于 Windows 上的键映射,或者至少是它的一个子集?
Is there any way I can set the key mapping on Ubuntu similar to what they were for Windows, or at least a subset of it?
推荐答案
我创建了一个提供默认 Windows 键绑定的扩展.它位于 VSCode 扩展市场 上,名为 Windows 默认键绑定.
I have created an extension that provides the default Windows keybindings. It is on the VSCode extension marketplace and called Windows Default Keybindngs.
我已经在 Linux 上使用 VSCode 1.38.0 和 1.36.1 对其进行了测试.
I have tested it on Linux with VSCode 1.38.0 and 1.36.1.
在存在冲突的情况下,新绑定优先,但现有的非冲突绑定仍然可用.
The new bindings take precedence where there is a conflict, but existing, non-conflicting bindings are still available.
基本上我所做的就是使用 HolyBlackCat 的建议运行首选项:打开默认键盘快捷键 (JSON)"并将结果填充到 package.json
中的适当位置.(加上文档并弄清楚如何发布它!)
Basically all I did was use HolyBlackCat's suggestion to run "Preferences: Open Default Keyboard Shortcuts (JSON)" and stuff the result into the appropriate place in package.json
. (Plus document it and figure out how to publish it!)
2020-06-05 更新:针对评论中的一个问题,我搜索了一下,发现 LinuxKeybindings,一个提供默认 Linux 绑定的扩展.我自己没有尝试过,但这对于那些想要 Linux 绑定而不是 Windows 绑定的人来说可能很有用.
Update 2020-06-05: In response to a question in a comment, I did a search and found LinuxKeybindings, an extension that provides the default Linux bindings. I have not tried it myself but this could be useful for those wanting the Linux bindings instead of Windows bindings.
这篇关于如何将 Windows 上的 VSCode 键映射转移到 ubuntu的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!