visual-studio-codegit-bash

Windows VS Code terminal takes about 5 seconds to return to command prompt after pressing Enter


I have tried all of the following:

Whenever I press Enter in the terminal it takes nearly 5 seconds to return to the command prompt.

I think this problem began when I had Docker running in the background and there was some lag and I hit Enter several times to put space between my last failed test. Now it's always taking so long. I am using Git Bash as my terminal. Git Bash terminal outside of VS Code is fast.

Why is VS Code using Git Bash as the terminal suddenly really slow?


Solution

  • Ok I solved the problem. Not sure why it went weird in the first place but this is it:

    1. Backup vscode settings.json AND make a note of extensions installed
    2. Uninstall vscode
    3. Uninstall gitbash - removes C:\Program Files\Git
    4. Delete all contents:
    1. Instal GitBash - with unix options etc
    2. Install Vscode 
      • Edit: settings.json C:\Users\steve\AppData\Roaming\Code\User\settings.json
      "terminal.integrated.profiles.windows": {
        "GitBash": { "path": "C:\\Program Files\\Git\\bin\\bash.exe", "icon": "terminal-bash" }
      },
      "terminal.integrated.defaultProfile.windows": "GitBash",
      "terminal.integrated.rendererType": "auto",
      "terminal.integrated.allowChords": false,
      "terminal.integrated.drawBoldTextInBrightColors": false,
      "terminal.integrated.experimentalLinkProvider": false,
      "terminal.integrated.gpuAcceleration": "off",
    

    Now the terminal is super fast !!!