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"
      }
]
相关推荐
曹牧1 小时前
Eclipse:悬停提示(Hover)
java·ide·eclipse
@ chen3 小时前
IDEA初始化配置
java·ide·intellij-idea
陈煜的博客5 小时前
idea 项目只编译不打包,跳过测试,快速开发
java·ide·intellij-idea
AI松子6669 小时前
vscode远程docker容器时报错
ide·vscode·docker
Mr-Wanter9 小时前
踩坑记录:IDEA 启动服务连续三次 OOM 内存溢出完整解决
java·ide·intellij-idea·oom
dgvri11 小时前
Node.js使用教程
node.js·编辑器·vim
计算机安禾12 小时前
【Linux从入门到精通】第10篇:软件包管理——Linux如何安装与卸载软件
java·linux·运维·服务器·编辑器
hjuan___12 小时前
给 Claude Code 装上“技能库”和“眼睛”:配置 Skills 与图片识别实战
vscode·minimax·mcp·ai 编程·claude code·cc switch
❀͜͡傀儡师13 小时前
GitHub Copilot for VS Code 中文使用完整教程
vscode·github·copilot
白头小黄13 小时前
ESP32+VScode+PIO实现基础的自带USB接口的JTAG调试
ide·vscode·编辑器