winget-cli icon indicating copy to clipboard operation
winget-cli copied to clipboard

Add logos to packages

Open SlimRG opened this issue 3 years ago • 8 comments

Today I develop my program WingetGUI So... I'd like to show logos of apps. In my opinion, it will be a good idea to have URL on logo of package New windows terminal also support images in title, so you can use this logo in installation progress too. What do you think about it?

SlimRG avatar Jul 03 '21 15:07 SlimRG

how would you show a logo via a command-line interface?

rbarbrow avatar Jul 04 '21 00:07 rbarbrow

Something like that? image

SlimRG avatar Jul 04 '21 09:07 SlimRG

how would you show a logo via a command-line interface?

It would just be ignored by the command-line winget. I think it's a good idea to have an OPTIONAL logo url in the manifest for GUI wrappers to consume.

jantari avatar Jul 05 '21 13:07 jantari

Yes, of course Logo URL should be only OPTIONAL parameter of manifest

SlimRG avatar Jul 05 '21 18:07 SlimRG

I had the same idea, but did not find this issue before i posted here: https://github.com/microsoft/winget-pkgs/issues/22577

I support this :+1:

khaffner avatar Jul 29 '21 10:07 khaffner

Definitely should be supported as the repo could/should definitely be resourced other than command line to be more useful and holistic.

drewid avatar Aug 10 '22 01:08 drewid

Should be a simple manifest addition

drewid avatar Aug 10 '22 01:08 drewid

Should be a simple manifest addition

Yes, I see two options:

  1. Encode the image in base64. Takes huge amount of space, but the maintainers have full control over the content of the image. Inelegant.
  2. A link to an image. This opens up to third parties modifying the image to something awful without winget knowing, except if we also have a field in the manifest for the hash of the image. The same way installer files are secured in the manifest. GUI implementations can then get the image, verify hash, and only show image if hashes match.

khaffner avatar Aug 10 '22 09:08 khaffner

We're tracking this work in:

  • https://github.com/microsoft/winget-cli/issues/3026

The schema support has been added to the 1.5 schema. The WinGet community repository will not accept manifests with the icon fields included (by policy), but we will be fetching them during validation, and exposing them via the COM API so other GUI based solutions can display them. Once the back-end work is completed, all 1.5 manifests will be used as the signal to capture the icon and make it available via a URL, and the SHA256 for the image and the image type will be automatically included in the manifests served by WinGet even though this metadata will not be in the winget-pkgs repository.

Note: The Dev Home experience will provide an example of how to implement this once it's all wired up.

https://github.com/microsoft/winget-cli/blob/83cd0dcaddd31cc64570422b081f7743a79dc10d/schemas/JSON/manifests/v1.5.0/manifest.defaultLocale.1.5.0.json#L54-L112

denelon avatar Jun 12 '23 17:06 denelon