首页 > 解决方案 > 如何阻止 PowerShell 集成终端出现在 VScode 启动时?

问题描述

我使用 Git Bash 作为内部和外部终端,基本上从不使用 powershell。我已经尝试相应地设置 VScode,这是我的 settings.json:

{
  "C_Cpp.errorSquiggles": "Enabled",
  "terminal.integrated.profiles.windows": {
    
    "PowerShell": null,
    "Command Prompt": null,
    "Git Bash": {
      "source": "Git Bash",
      "path": ["C:\\Program Files\\Git\\bin\\bash.exe"],
      "icon": "terminal-bash"
    }
  },
  "terminal.integrated.defaultProfile.windows": "Git Bash",
  "terminal.integrated.automationShell.windows": "Git Bash",
  "terminal.integrated.enablePersistentSessions": false,
  "terminal.external.windowsExec": "C:\\Program Files\\Git\\bin\\bash.exe"
}

现在 Ctrl+` 对我来说在集成终端中启动 Git Bash,这是我的目标,但是 VScode 在启动时仍然不启动任何东西或启动 powershell,这很烦人。有没有办法阻止 VScode 这样做?

标签: bashpowershellvisual-studio-code

解决方案


推荐阅读