scoop-nonportable icon indicating copy to clipboard operation
scoop-nonportable copied to clipboard

powertoys-np: is dotnet-sdk dependency really needed?

Open protron opened this issue 3 years ago • 4 comments

Seems like the PowerToys dependency on dotnet-sdk was added in https://github.com/TheRandomLabs/scoop-nonportable/commit/8576c2eeabb504d878630966542ce7c5c79359cc when it was using MSI installer in their version 0.18.1. And later in their version 0.20 they changed their installer to automatically install .NET Core if needed: https://github.com/microsoft/PowerToys/issues/3341

So I wonder if this dependency can be removed.

On the other hand, while creating this issue I searched for what Chocolatey did on version 0.20 of PowerToys, and they added a dependency to "dotnetcore3-desktop-runtime" and used the "--silent --skip_dotnet_install" options on PowerToys installer. And they seem to keep both of those as of today (dependency and options).

But current scoop package requires the .NET 5.0 SDK, while Chocolatey package and PowerToys only require the 3.1 Desktop Runtime (which takes 52MB instead of 182MB).

I also read scoop's Dependencies documentation "It's OK to just install the latest version". I'm still not sure if that extends to Runtimes vs SDK, and if in this context if the scoop package will be better without that dependency.

Because PowerToys installer will also automatically install it only when needed, and will correctly figure out that I already have it. While scoop asks me to install it just because I don't have it installed via Scoop.

protron avatar Feb 28 '21 12:02 protron

Do you think it would be better to not specify any dependency or to create a new manifest for .NET Core 3.1 Desktop Runtime?

TheRandomLabs avatar Mar 01 '21 11:03 TheRandomLabs

I think the best would probably be to create a new manifest for .NET Desktop Runtime (maybe Core 3.1, but I would consider the latest version due to "It's OK to just install the latest version") but define it in a way that when installed as a dependency it would check if it already installed not only via scoop.

But I think this would probably require changes to scoop itself (not only to this package). And I don't know enough about scoop to estimate the complexity of making those changes and what negative consequences can it bring. So I think this last idea would probably belong to the main scoop repo, right?

And I posted this question here because: 1) maybe any change would be beneficial, and I'm not really sure which is the best change in this case (I don't have any experience developing a scoop package), and 2) even if it's better to left this unchanged, I think the research might in the future help others with similar questions/concerns.

So I hope not having taking much of your time. Feel free to close this issue if you consider that's best.

protron avatar Mar 01 '21 13:03 protron

That last idea would indeed belong to the main scoop repo, and unfortunately, I'm not sure if it would ever be implemented. I'll leave this open for now.

TheRandomLabs avatar Mar 02 '21 11:03 TheRandomLabs

Not anymore :)

"The .NET 7 dependency is now shipped self-contained within the utilities" Source: https://github.com/microsoft/PowerToys/releases/tag/v0.66.0

https://visualstudiomagazine.com/articles/2023/01/06/powertoys-net7.aspx

cvladan avatar Jan 10 '23 23:01 cvladan