Home > Blockchain >  VSCode: Insert suggestion from debug console with Enter instead of tab on Ubuntu
VSCode: Insert suggestion from debug console with Enter instead of tab on Ubuntu

Time:02-16

I run VSCode on my mac and Ubuntu machines and sync settings between them. However, I am seeing a different behavior between the machines. On my mac, I can insert a suggestion by pressing enter. insert

But on Ubuntu, I have to use tab. I would like to use enter for both. I have the setting "editor.acceptSuggestionOnEnter": "smart" on both machines. I tried changing this to "editor.acceptSuggestionOnEnter": "on" but this had no effect. Is there something that I'm failing to sync? How can I accept the suggestion with enter on Ubuntu?

CodePudding user response:

Method1: Go to Keyboard shortcuts then set acceptSelectedSuggestion to Enter.

Method2: Open keybindings.json and replace tab with enter as follows:

    { "key": "enter",
      "command": "acceptSelectedSuggestion",
    "when": "suggestWidgetVisible && textInputFocus"
}```
  • Related