我正在尝试将新终端(Git Bash)添加到新的 Windows 终端。但是,我无法让它工作。
我尝试将数组中的commandline属性更改为但没有运气。profiles``git-bash.exe
commandline
profiles``git-bash.exe
有谁知道如何让它工作?
Ctrl
,
"list":
settings.json
{ "$schema": "https://aka.ms/terminal-profiles-schema", "defaultProfile": "{00000000-0000-0000-ba54-000000000001}", "profiles": { "defaults": { // Put settings here that you want to apply to all profiles }, "list": [ <put one of the configuration below right here> ] } }
取消注释正确的路径commandline,icon如果您正在使用:
icon
%PROGRAMFILES%
%USERPROFILE%
如果你使用勺子
{ “guid”: “{00000000-0000-0000-ba54-000000000002}”, “commandline”: “%PROGRAMFILES%/git/usr/bin/bash.exe -i -l”, // “commandline”: “%USERPROFILE%/AppData/Local/Programs/Git/bin/bash.exe -l -i”, // “commandline”: “%USERPROFILE%/scoop/apps/git/current/usr/bin/bash.exe -l -i”, “icon”: “%PROGRAMFILES%/Git/mingw64/share/git/git-for-windows.ico”, // “icon”: “%USERPROFILE%/AppData/Local/Programs/Git/mingw64/share/git/git-for-windows.ico”, // “icon”: “%USERPROFILE%/apps/git/current/usr/share/git/git-for-windows.ico”, “name” : “Bash”, “startingDirectory” : “%USERPROFILE%” },
您还可以添加其他选项,例如:
{ "guid": "{00000000-0000-0000-ba54-000000000002}", // ... "acrylicOpacity" : 0.75, "closeOnExit" : true, "colorScheme" : "Campbell", "cursorColor" : "#FFFFFF", "cursorShape" : "bar", "fontFace" : "Consolas", "fontSize" : 10, "historySize" : 9001, "padding" : "0, 0, 0, 0", "snapOnInput" : true, "useAcrylic" : true }
guid
guid可以在globals>中使用,defaultProfile所以你可以按你可以按Ctrl``Shift``T 或启动一个 Windows 终端,它会默认启动 bash
globals
defaultProfile
Ctrl``Shift``T
“defaultProfile” : “{00000000-0000-0000-ba54-000000000001}”,
-l -i确保.bash_profile加载
-l -i
.bash_profile
git/bin/bash.exe
我的配置在https://gist.github.com/trajano/24f4edccd9a997fad8b4de29ea252cc8中使用 Scoop