I've worked with Windows Terminal for a while. Recently, I wanted to add some additional 3rd party command line tools into dynamic profiles in Windows Terminal.
It must be successful if using commandline
. But if not used, how does the Windows Terminal find our target items?
Maybe out of curiosity, I cannot understand the automatically created profiles, such as WSL
or PowerShell
:
{
"guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
"hidden": false,
"name": "PowerShell",
"source": "Windows.Terminal.PowershellCore"
},
{
"guid": "{d7b20cea-47a9-518c-95a4-c8bd91e2e1c6}",
"hidden": false,
"name": "Ubuntu 22.04.2 LTS",
"source": "CanonicalGroupLimited.Ubuntu22.04LTS_79rhkp1fndgsc"
},
I've done some ablation experiments and found the following points:
- If I comment out the
name
andsource
ofPowerShell
, but retain theguid
, this profile will still work. - If I comment out the
guid
ofPowerShell
, but retain the other settings, this profile will not work. - If I comment out the
name
andsource
ofUbuntu 22.04.2 LTS
, but retain theguid
, this profile will still work. - If I comment out the
guid
ofUbuntu 22.04.2 LTS
, but retain other settings, this profile will still work.
My problems are:
- How can Windows Terminal find the target by the GUID?
- Why in the above samples, can
Ubuntu 22.04.2 LTS
still be found when given only thesource
andname
and withoutguid
? - If so, why can't, in the above sample, the
PowerShell
be found when given only thesource
andname
and withoutguid
?