Closed maximousblk closed 3 years ago
You have to add them yourselves. Microsoft can't use the Ubuntu logo to ship it directly with the Terminal I believe
Yea, this is by design. Legally, I don't think we're allowed to ship the logos of other distros - Canonical maintains that copyright 😜
We are working on something that will allow them to ship a "settings fragment", so they can set the icon for their profile to whatever they'd like. That work is being tracked over in #7632 and #1690
PROTIP: Go to https://ubuntu.com/ and add /favicon.ico
to the end of the URL like https://ubuntu.com/favicon.ico and save the image
Ah that makes sense
You have to add them yourselves. [...] - @itsme-alan
How tho? "source": "Windows.Terminal.Wsl"
is not specific to Ubuntu. Wouldn't it add the same icon to all the distros? I see it in the documentation. screenshot so I assume it is possible to customize individual WSL distro profiles (?), but I couldn't find a "how to" in the docs
Nah, each distro will get it's own profile. The source
field is just a property indicating that this setting came from the "WSL dynamic profile generator". So you can modify the Ubuntu profile all you want, and it'll only affect that version of Ubuntu.
See the docs on setting an icon here.
For example, my 20.04 profile looks like:
{
"guid": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}",
"hidden": false,
"name": "Ubuntu-20.04",
"source": "Windows.Terminal.Wsl",
"startingDirectory" : "\\\\wsl$\\Ubuntu-20.04\\home\\zadjii",
"background" : "#2C001E",
"tabColor" : "#2C001E",
"acrylicOpacity" : 0.9,
"closeOnExit" : true,
"colorScheme" : "Tango Dark",
"cursorColor" : "#FFAF00",
"cursorShape" : "emptyBox",
"fontFace" : "Ubuntu Mono",
"fontSize" : 12,
"historySize" : 9001,
"icon" : "C:\\Users\\migrie\\Downloads\\shell-icons\\ubuntu-icon.png",
"antialiasingMode": "grayscale",
"backgroundImage": "C:\\Users\\migrie\\Downloads\\Focal-Fossa_Plain_WP_1920x1080.png",
"backgroundImageStretchMode": "none",
"backgroundImageOpacity": 0.55,
}
just to make sure, is this correct?
{
"guid": "{2c4de342-38b7-51cf-b940-2309a097f517}",
"name:": "Ubuntu"
"source": "Windows.Terminal.Wsl",
"icon" : "C:\\Users\\maximousblk\\.wt\\icons\\ubuntu.png",
"hidden": false
},
{
"guid": "{2c4de342-38b7-51cf-b940-2309a097f518}",
"name:": "Arch"
"source": "Windows.Terminal.Wsl",
"icon" : "C:\\Users\\maximousblk\\.wt\\icons\\arch.png",
"hidden": false
},
{
"guid": "{2c4de342-38b7-51cf-b940-2309a097f519}",
"name:": "Bebian"
"source": "Windows.Terminal.Wsl",
"icon" : "C:\\Users\\maximousblk\\.wt\\icons\\debian.png",
"hidden": false
}
yes
Did you misspell Debiun?
we're not so different, you and I
If you want to use the official icons, you should copy paste this in place: (3 examples, Ubuntu, Debian and kali-linux)
{
"guid": "{58ad8b0c-3ef8-5f4d-bc6f-13e4c00f2530}",
"hidden": false,
"icon": "https://www.debian.org/favicon.ico",
"name": "Debian",
"source": "Windows.Terminal.Wsl"
},
{
"guid": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}",
"hidden": false,
"icon": "https://assets.ubuntu.com/v1/49a1a858-favicon-32x32.png",
"name": "Ubuntu-20.04",
"source": "Windows.Terminal.Wsl"
},
{
"guid": "{46ca431a-3a87-5fb3-83cd-11ececc031d2}",
"hidden": false,
"icon": "https://www.kali.org/images/favicon.png",
"name": "kali-linux",
"source": "Windows.Terminal.Wsl"
}
**Consider this like an option to get better contrast in explorer when you are using a dark theme on Windows: (in this example, in the case of kali-linux), replace
"icon": "https://www.kali.org/images/favicon.png",
whith
"icon": "https://www.kali.org/images/favicon-dark.png",
For more tips, please, feel free to follow me on github
You have to add them yourselves. Microsoft can't use the Ubuntu logo to ship it directly with the Terminal I believe
How did you install arch Linux?
https://docs.microsoft.com/en-us/windows/wsl/use-custom-distro
This should show you how to do it. The guide shows you how to install CentOS but you can install archlinux
Anyway, isn't there a place in Windows where the Ubuntu logo can be found instead of downloading it remotely? I think it comes with the appx.
Yes, you can add it like this: "icon": "C:/Program Files/WindowsApps/CanonicalGroupLimited.UbuntuonWindows_2004.2020.812.0_neutral_split.scale-100_79rhkp1fndgsc/Assets/Square150x150Logo.scale-100.png"
Hm... that works. Unfortunately, the path changes every time it gets updated from the Windows Store.
I still think Windows Terminal should find the icon by itself, by looking at the executable for the installed distribution.
Yea, this is by design. Legally, I don't think we're allowed to ship the logos of other distros - Canonical maintains that copyright 😜
We are working on something that will allow them to ship a "settings fragment", so they can set the icon for their profile to whatever they'd like. That work is being tracked over in #7632 and #1690
@zadjii-msft following up on this, what about fetching the icon from the WSL package or executable? That would not imply shipping the icon with Terminal itself.
I'm not sure how feasible that would be. Technically, each distro is free to set up their app package however they want, and I'm not sure the registry includes info as to the exe responsible for that distro. IIRC you can also like side-load distros without an app package, so that might also be out of the question.
In 1.17 we did add support for setting the icon
to an exe
and automatically using the exe's icon. I dunno if this works for app exe's like ubuntu.exe
though, since those are technically app execution aliases (a fancy kind of symlink)
Yeah, the "alias" doesn't work indeed:
But it doesn't seem to have an icon anyway.
The actual .exe
"C:\Program Files\WindowsApps\CanonicalGroupLimited.Ubuntu_2204.2.33.0_x64__79rhkp1fndgsc\ubuntu.exe" works to get the icon from though.
I have discovered a bug testing this though: https://github.com/microsoft/terminal/issues/15581
So, thanks for the details. I'll let you know if I discover something.
Environment
Steps to reproduce
Not totally sure if this is intended behavior or a bug, but this is the WSL profile:
Expected behavior
Show the Ubuntu logo for Ubuntu.
image from docs.microsoft.com/windows/terminal/dynamic-profiles
Actual behavior
Windows terminal instead shows the Tux logo
PS: I'd suggest enabling GitHub Discussions for issues like this which are more help/question than a bug report.