VS Code 如何將默認終端設置為 Git Bash
Copyright Notice: This article is an original work licensed under the CC 4.0 BY-NC-ND license.
If you wish to repost this article, please include the original source link and this copyright notice.
Source link: https://v2know.com/article/1266
在日常開發中,如果你經常使用 Git Bash,完全可以讓 VS Code 新建終端時直接打開它,省去每次手動切換的步驟。
操作步驟(Windows / macOS 通用)
-
打開 VS Code,按下
Ctrl + Shift + P
(macOS 為Cmd + Shift + P
)呼出命令面板。 -
在搜索框輸入
Terminal: Select Default Profile
(中文介面可能顯示為「終端:選擇預設配置檔」),並選中它。 -
在彈出的列表中選擇 Git Bash。
-
之後按 `Ctrl + Shift + ``(反引號)打開新終端,就會自動以 Git Bash 啟動。
💡 提示
-
如果列表裡沒有 Git Bash,檢查你的 Git 是否安裝並已添加到系統 Path 中。
-
此設置僅影響 VS Code 內建終端,不會改變系統的默認終端。
This article was last edited at