MSYS shell in Windows Terminal Preview?
Solution 1:
Assuming MSYS2 is installed in C:\msys2
folder, the commandline entry for Windows Terminal will be C:\msys2\usr\bin\bash.exe -i -l
. Hence the entry in profile.json
will be:
{
// Make changes here to the MSYS2 profile
"guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
"name": "msys2",
"commandline": "C:\\msys2\\usr\\bin\\bash.exe -i -l",
"hidden": false
},
The command launches bash.exe
from MSYS2 environment with --interactive
and --login
options. Those options are necessary to set up environment specific to MSYS2 only. For more information about how to add entry in Windows Terminal profile.json
file, see this documentation from Microsoft Temrminal GitHub repository.