0%

VSCode 配置超级搜索快捷键小记

主要是通过宏变量实现自动传递搜索参数的效果, 避免忘记记录一下.

修改 keybindings.json 视情况添加以下内容:

[
    {
        "key": "ctrl+shift+f",
        "command": "workbench.action.findInFiles",
        "args": {
            "triggerSearch": true,
            "query": "${selectedText}",
        }
    },
    {
        "key": "ctrl+shift+alt+f",
        "command": "search.action.openNewEditor",
        "args": {
            "filesToInclude": "${fileBasename}",
            "showIncludesExcludes": true,
            "triggerSearch": true,
            "focusResults": true,
            "query": "${selectedText}",
            "contextLines": 0
        }
    }
]
  • 本文作者: 6x
  • 本文链接: https://6xyun.cn/article/241
  • 版权声明: 本博客所有文章除特别声明外,均采用 BY-NC-ND 许可协议。转载请注明出处!