2021년 VSCode에서 Git Bash를 통합 터미널로 설정하는 방법
"terminal.integrated.profiles.windows": {
"PowerShell": { "source": "PowerShell", "icon": "terminal-powershell" },
"Command Prompt": {
"path": [
"${env:windir}\\Sysnative\\cmd.exe",
"${env:windir}\\System32\\cmd.exe"
],
"icon": "terminal-cmd"
},
"GitBash": {
"path": ["C:\\Program Files\\Git\\bin\\bash.exe"],
"source": "Git Bash",
"icon": "terminal-bash"
},
"terminal.integrated.defaultProfile.windows": "GitBash",
2021년 4월부터 "terminal.integrated.shell.windows"는 VSCode에서 더 이상 사용되지 않습니다.
"terminal.integrated.shell.windows": "C:\\...\\...\\bin\\bash.exe",
Windows 10의 VSCode 버전 1.56에서 Git Bash를 기본 통합 터미널로 구성하려면
1단계: 명령 팔레트 열기(CMD + Shift + P)
2단계: "기본 설정: 사용자 설정 열기(JSON)"검색
3단계: ""(큰따옴표 키)를 입력하여 새 필드를 만듭니다. 인용 유형 "터미널"내부. 옵션 목록이 나타납니다.
4단계:
terminal.integrated.profiles.windows
를 선택합니다. terminal.integrated.profiles.windows
를 선택하면 다음으로 확장됩니다."terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"icon": "terminal-powershell"
},
"Command Prompt": {
"path": [
"${env:windir}\\Sysnative\\cmd.exe",
"${env:windir}\\System32\\cmd.exe"
],
"args": [],
"icon": "terminal-cmd"
},
"GitBash": {
"source": "Git Bash",
"path": ["C:\\Program Files\\Git\\bin\\bash.exe"],
"icon": "terminal-bash"
}
},
5단계: 기본 터미널을 Git Bash로 설정
"terminal.integrated.defaultProfile.windows": "GitBash",
중요한
defaultProfile.windows 값이 작동하려면 한 단어여야 합니다.
"terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"icon": "terminal-powershell"
},
"Command Prompt": {
"path": [
"${env:windir}\\Sysnative\\cmd.exe",
"${env:windir}\\System32\\cmd.exe"
],
"icon": "terminal-cmd"
},
"Git Bash": {
"path": ["C:\\Program Files\\Git\\bin\\bash.exe"],
"source": "Git Bash",
"icon": "terminal-bash"
},
},
"terminal.integrated.defaultProfile.windows": "Git Bash",
작동하지 않습니다!
//끝
선적 서류 비치:
VSCode version 1.56 Release Notes
https://code.visualstudio.com/docs/editor/integrated-terminal#_windows
관련된
Reference
이 문제에 관하여(2021년 VSCode에서 Git Bash를 통합 터미널로 설정하는 방법), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://dev.to/andrewriveradev/how-to-set-git-bash-as-integrated-terminal-in-vscode-2k31텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념 (Collection and Share based on the CC Protocol.)