How to change the integrated terminal in visual studio code or VSCode

前端 未结 8 857
轮回少年
轮回少年 2020-12-12 21:46

I want to change integrated terminal to CMDER i use Vscode on windows 8.1 i checked the doc and also preference file but i got confuse so from following line

相关标签:
8条回答
  • 2020-12-12 22:27

    It is possible to get this working in VS Code and have the Cmder terminal be integrated (not pop up).

    To do so:

    1. Create an environment variable "CMDER_ROOT" pointing to your Cmder directory.
    2. In (Preferences > User Settings) in VS Code add the following settings:

    "terminal.integrated.shell.windows": "cmd.exe"

    "terminal.integrated.shellArgs.windows": ["/k", "%CMDER_ROOT%\\vendor\\init.bat"]

    0 讨论(0)
  • 2020-12-12 22:27

    From Official Docs

    Correctly configuring your shell on Windows is a matter of locating the right executable and updating the setting. Below is a list of common shell executables and their default locations.

    There is also the convenience command Select Default Shell that can be accessed through the command palette which can detect and set this for you.

    So you can open a command palette using ctrl+shift+p, use the command Select Default Shell, then it displays all the available command line interfaces, select whatever you want, VS code sets that as default integrated terminal for you automatically.

    If you want to set it manually find the location of executable of your cli and open user settings of vscode(ctrl+,) then set

    "terminal.integrated.shell.windows":"path/to/executable.exe"
    

    Example for gitbash on windows7:

    "terminal.integrated.shell.windows":"C:\\Users\\stldev03\\AppData\\Local\\Programs\\Git\\bin\\bash.exe",
    
    0 讨论(0)
提交回复
热议问题