Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.NET Core 3.0 support #1374

Open
themightylc opened this issue Aug 18, 2018 · 22 comments
Open

.NET Core 3.0 support #1374

themightylc opened this issue Aug 18, 2018 · 22 comments
Labels
infrastructure Pull requests related dependencies, tooling or testing that the project needs

Comments

@themightylc
Copy link

Are there any plans to support .NET Core 3.0? I've run the compatibility analysis tool and quite a few issues with Squirrel pop up - all of them categorized as "not supported".
I am very much interested to moving my WPF application to .NET Core 3.0 and it would be a shame (mildly put) to lose Squirrel.
I am quite confident that I won't be able do it myself. :)

@anaisbetts
Copy link
Contributor

@themightylc You can use Squirrel with .NET Core similarly to how non-C# applications use Squirrel, by running Update.exe, instead of using the C# API

@themightylc
Copy link
Author

themightylc commented Aug 18, 2018 via email

@shiftkey shiftkey added the infrastructure Pull requests related dependencies, tooling or testing that the project needs label May 5, 2019
@mihaimyh
Copy link

@anaisbetts You mean by calling Update.exe from c# code like below?

Process.Start("Update.exe");

@anaisbetts
Copy link
Contributor

@mihaimyh u got it, but you need to use GetEntryAssembly to get your own path, then go up a directory

@mihaimyh
Copy link

@anaisbetts How should I handle this situation in debugging mode? I won't have Update.exe in my debugging folder. Should I include Squirrel.exe in the solution?

@mihaimyh
Copy link

Another suggestion is: with net .net-core 3 we are able to generate a nuget package for our project right from Visual Studio by adding the following to the .csproj:

<GeneratePackageOnBuild>true</GeneratePackageOnBuild>

It will be useful if squirrel can releasify that package instead.

@anaisbetts
Copy link
Contributor

@mihaimyh don't run updates in debug mode, that's silly!

As to .Net Core, the packages they generate are useless, you have to package manually, sorry

@mihaimyh
Copy link

@anaisbetts Thanks, my question was rather about debugging the updates, but I found my answer here https://github.com/Squirrel/Squirrel.Windows/blob/develop/docs/using/debugging-updates.md

@mihaimyh
Copy link

Is there a way to find if the .net-core version of the app was installed successfully by Squirrel before I should proceed with uninstalling the ClickOnce version?

@anaisbetts
Copy link
Contributor

If your app is running, it worked! Put the ClickOnce uninstaller in your app

@eduardomhg
Copy link

Are there any plans to port the squirrel.windows NuGet package to .NET Standard/.NET Core so we can use the UpdateManager in a .NET Core 3 WPF application (for example)?

@Macready31
Copy link

@eduardomhg Squirrel ports to .Net core pretty cleanly. The most irritating part was that its dependent packages need to be upgraded to .Net Standard versions, and there were some breaking API changes in at least a couple (Splat and SharpCompress IIRC), and a couple others didn't offer .Net Standard packages at all (Delta Compression, WpfAnimation). But fortunately everything is open source, so it was fairly straightforward to track down the relevant commits and see what changes were required, and to create builds of the projects that hadn't yet been ported.

There's a special circumstance with migrating to Core, though. Anyone with an existing legacy framework application in the field (like me) is in a weird spot. Squirrel handles the underlying framework dependency via its setup program, but users are past that step. So we either have to ask them to install the Core runtime, or live with self-contained dists.

Anyway, I am doing functional and integration testing on the migrated projects as time allows. If I make it as far as a successful Squirrel deployment of my own application's .Net Core port, I'll consider my efforts successful and share what I've done.

@anaisbetts
Copy link
Contributor

Are there any plans to port the squirrel.windows NuGet package to .NET Standard/.NET Core so we can use the UpdateManager in a .NET Core 3 WPF application (for example)?

No, Squirrel's current API is basically set in stone. vNext would probably provide a similar API as a shim, but afaik zero people are working on it. I would not try to port Squirrel to .NET Core wholesale, I'd try to write a version of UpdateManager that uses the non-C# API

@Stijn98s
Copy link

Stijn98s commented Nov 9, 2019

I have got it working with a Winforms .net core 3.0 application

@mihaimyh
Copy link

I have got it working with a Winforms .net core 3.0 application

Mind sharing implementation details?

@Stijn98s
Copy link

it is the same as .net framework. you can use de example .nuspec and change the implementing files to bin\Debug\netcoreapp3.0\*.*. Here is mine https://pastebin.com/wVEZSxnr. Also with .net core you can automaticly generate the .nuspec and .nupkg with setting true in the .csproj (https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package-using-the-dotnet-cli)

@Stijn98s
Copy link

and downgrade to 1.9.0. with 1.9.1 i couldn't access the namespace. still debugging why

@bbilginn
Copy link

it is the same as .net framework. you can use de example .nuspec and change the implementing files to bin\Debug\netcoreapp3.0\*.*. Here is mine https://pastebin.com/wVEZSxnr. Also with .net core you can automaticly generate the .nuspec and .nupkg with setting true in the .csproj (https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package-using-the-dotnet-cli)

exclude worked like this <file src="bin\Release\netcoreapp3.1\publish\*.*" target="lib\netcoreapp3.1\" exclude="**\*.pdb;**\*.nupkg;**\*.vshost.*"/>

thanks for your comments

@Jonesie
Copy link

Jonesie commented May 26, 2020

it is the same as .net framework. you can use de example .nuspec and change the implementing files to bin\Debug\netcoreapp3.0\*.*. Here is mine https://pastebin.com/wVEZSxnr. Also with .net core you can automaticly generate the .nuspec and .nupkg with setting true in the .csproj (https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package-using-the-dotnet-cli)

exclude worked like this <file src="bin\Release\netcoreapp3.1\publish\*.*" target="lib\netcoreapp3.1\" exclude="**\*.pdb;**\*.nupkg;**\*.vshost.*"/>

thanks for your comments

If my app is a standalone publish Im assuming I dont have any framework dependencies?

@bbilginn
Copy link

it is the same as .net framework. you can use de example .nuspec and change the implementing files to bin\Debug\netcoreapp3.0\*.*. Here is mine https://pastebin.com/wVEZSxnr. Also with .net core you can automaticly generate the .nuspec and .nupkg with setting true in the .csproj (https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package-using-the-dotnet-cli)

exclude worked like this <file src="bin\Release\netcoreapp3.1\publish\*.*" target="lib\netcoreapp3.1\" exclude="**\*.pdb;**\*.nupkg;**\*.vshost.*"/>
thanks for your comments

If my app is a standalone publish Im assuming I dont have any framework dependencies?

Unfortunately. I think it will happen when squirrel gives for 3.x support in the future.

@MuhammadNoman-SE
Copy link

@anaisbetts any complete example with .NET 5.0?

@legistek
Copy link

legistek commented Oct 8, 2021

@themightylc You can use Squirrel with .NET Core similarly to how non-C# applications use Squirrel, by running Update.exe, instead of using the C# API

@anaisbetts is there any documentation for how to do this? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Pull requests related dependencies, tooling or testing that the project needs
Projects
None yet
Development

No branches or pull requests