Reputation: 25
Its being a while where I am using VIM with VS Code. But my current project require use of Visual Studio. While setting vim for vs code I have modified my settings.json and keybindings.json files. How do apply that kind of modifications in Visual Studio 2022.
Following are two files from vscode.
settings.json
{
"vim.easymotion": true,
"vim.incsearch": true,
"vim.useSystemClipboard": true,
"vim.useCtrlKeys": false,
"vim.hlsearch": true,
"vim.insertModeKeyBindings": [
{
"before": ["j", "j"],
"after": ["<Esc>"]
}
],
"vim.normalModeKeyBindingsNonRecursive": [
{
"before": ["<leader>", "d"],
"after": ["d", "d"]
},
{
"before": ["<C-n>"],
"commands": [":nohl"]
}
],
"vim.leader": "<space>",
"vim.handleKeys": {
"<C-a>": false,
"<C-f>": false
},
}
keybindings.json
[
{
"key": "tab",
"command": "tab",
"when": "editorTextFocus && !editorTabMovesFocus"
},
{
"key": "shift-tab",
"command": "outdent",
"when": "editorTextFocus && !editorTabMovesFocus"
}
]
Note: I have installed VsVim 2022 extension on Visual Studio 2022.
Upvotes: 0
Views: 2951
Reputation: 3
While in Visual Studio type
:set vimrcpaths?
This will show you directory where the plugin looks for the .vimsrc file. Place the config file there and restart Visual Studio.
I assume you have the VsVim extension installed (it's different than the one for VS Code).
Upvotes: 0