StephanTLavavej / mingw-distro

MinGW distro build scripts.
503 stars 57 forks source link

integration with windows terminal #75

Closed GautamDMan closed 4 years ago

GautamDMan commented 4 years ago

Hi.

I am trying to get a new tab settings to work for your Mingw distro using the "set_distro_paths.bat" in the cmd to set the env vars. Is there any setting I can use to set this distro paths when a new cmd instance is spawned in the terminal.

I have tried below setting, but with no success::

{ // Make changes here to the cmd.exe profile "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6111}", "name": "cmd", "commandline": "cmd.exe /k 'C:\MinGW\set_distro_paths.bat'", "colorScheme": "One Half Dark", "startingDirectory": "%USERPROFILE%\Desktop", "hidden": false },

the error i keep getting is : err

Any suggestions to set these paths alternatively ?

StephanTLavavej commented 4 years ago

I don't know what line 26, column 28 of your file is. It might be the single-quoted 'C:\MinGW\set_distro_paths.bat'. I haven't used the Windows Terminal, but reading https://github.com/microsoft/terminal/blob/master/doc/user-docs/UsingJsonSettings.md leads me to believe that you shouldn't be using single quotes here, and should instead be using double backslashes: C:\\MinGW\\set_distro_paths.bat. The same may apply to the startingDirectory.

GautamDMan commented 4 years ago

oh yeah yeah !! that worked perfectly. The paths are really mix and match inside the settings json. Perhaps adding extra single quotes was the problem.

my setting now:: { // Make changes here to the cmd.exe profile "guid":"{0caa0dad-35be-5f56-a8ff-afceeeaa6123}", "name":"NUWEN-GCC", "commandline":"cmd.exe /k C:\MinGW\set_distro_paths.bat", "icon":"C:\MinGW\gcc-icon.png", "colorScheme":"One Half Dark", "startingDirectory":"%USERPROFILE%\Desktop", "hidden":false },

UI:: it-works

Thanks a lot !!