VSCode 注释后光标快速定位下一行

VSCode默认用 Ctrl + / 注释一行时,光标停留在该行中。下面介绍如何注释后,光标会自动移动到下一行。

1.【View】 ->【Extensions】->【查找并安装Multi-command 扩展】

2.【File 】 -> 【Preferences 】->【Keyboard Shortcuts】(macOS :Code ,Preferences ,Keyboard Shortcuts)

3.【在搜索栏里面搜索 Open Keyboard Shortcuts (JSON)】->【去到别的文件下,打开Keybinding.json】

如果Keybinding是空的,则自己随便设置一个快捷键,去到别的文件下,按下快捷键打开keybindings.json

4.在keybindings.json文件下添加以下代码

json 复制代码
[
    {
        "key": "ctrl+/",
        "command": "extension.multiCommand.execute",
        "args": {
          "sequence": [
            "editor.action.commentLine",
            "cursorDown"
          ]
        },
        "when": "editorTextFocus"
      }
]
相关推荐
番茄去哪了3 小时前
苍穹外卖day05----店铺营业状态设置
java·数据库·ide·redis·git·maven·mybatis
西柚云4 小时前
把Codex装进VSCode!OpenAI编程助手插件版来了
服务器·ide·vscode·ai编程·codex
推理幻觉6 小时前
vs code ssh使用codex
vscode·ssh·codex
小付同学呀12 小时前
Visual Studio2026企业版使用教程
ide·visual studio
我命由我1234512 小时前
Visual Studio - Visual Studio 修改项目的字符集
c语言·开发语言·c++·ide·学习·visualstudio·visual studio
十铭忘12 小时前
windows下右键没有通过Vscode打开
ide·windows·vscode
yuezhilangniao13 小时前
【AI 编辑器开发规范 v2.1 版】—— 为 AI 时代的敏捷开发而生
人工智能·编辑器·敏捷流程
红叶尽染寂绀蓝14 小时前
已解决:同一ip下,Mac和Windows同时用vscode连接某个Linux远程服务器后,Mac再次连接时无法正确打开远程文件夹,由于转发设置导致
linux·服务器·windows·vscode·tcp/ip·macos
Nicolas89314 小时前
解决Cursor连远程服务器慢的问题
服务器·vscode·cursor·速度慢·连接远程服务器·ai编程ide
没有bug.的程序员1 天前
IDEA 效能巅峰实战:自定义模板 Live Templates 内核、快捷键精密逻辑与研发提效深度指南
java·ide·intellij-idea·快捷键·研发提效·自定义模板