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

Get back net6 support #849

Merged
merged 2 commits into from
May 1, 2024

Conversation

gorsheninmv
Copy link

.NET6 support is valid until November 12, 2024, more than half a year, I'm not sure this is a good idea to abandon .NET6 support in Electron.NET.

I would like to suggest making the project multitarget and support both LTS versions (.NET6 and .NET8)

dotnet tool doesn't support self-contaied tools (see dotnet/sdk#9565), so that <PublishSelfContained>true</PublishSelfContained> can be useful only for binaries but not for dotnet tool so I decided to remove the line

@gorsheninmv gorsheninmv changed the title fix: get back net6 support Get back net6 support May 1, 2024
Copy link
Collaborator

@FlorianRappl FlorianRappl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general the multi target approach works for me - just not sure about the execution in there.

What we'd need is that the published NuGet package contains both frameworks; still the dotnet commands are run with an explicit framework derived from the ElectronNET.WebApp project.

Just wondering if this is achieved here; maybe only the contained tools is then .NET 8, but the libs contains both.

@gorsheninmv
Copy link
Author

gorsheninmv commented May 1, 2024

The structure of CLI dotnet tool package I got after executing dotnet pack

.
|   ElectronNET.CLI.nuspec
|   PackageIcon.png
|   [Content_Types].xml
|   
+---package
|   \---services
|       \---metadata
|           \---core-properties
|                   553c89be248c4da09d1469f93f9abb2f.psmdcp
|                   
+---tools
|   +---net6.0
|   |   \---any
|   |           dotnet-electronize.deps.json
|   |           dotnet-electronize.dll
|   |           dotnet-electronize.pdb
|   |           dotnet-electronize.runtimeconfig.json
|   |           DotnetToolSettings.xml
|   |           
|   \---net8.0
|       \---any
|               dotnet-electronize.deps.json
|               dotnet-electronize.dll
|               dotnet-electronize.pdb
|               dotnet-electronize.runtimeconfig.json
|               DotnetToolSettings.xml
|               
\---_rels
        .rels

The structure of API package I got after executing dotnet pack

.
|   ElectronNET.API.nuspec
|   PackageIcon.png
|   [Content_Types].xml
|   
+---lib
|   +---net6.0
|   |       ElectronNET.API.dll
|   |       ElectronNET.API.xml
|   |       
|   \---net8.0
|           ElectronNET.API.dll
|           ElectronNET.API.xml
|           
+---package
|   \---services
|       \---metadata
|           \---core-properties
|                   3528134964fe4b75b8c25a49aef2d054.psmdcp
|                   
\---_rels
        .rels

I double checked if the packages worked correctly with my .NET6 app and .NET8 demo webapp.
Let me know if I should check something else.

@FlorianRappl
Copy link
Collaborator

No structure looks fine to me!

Let's keep it like that - thanks for checking!

@FlorianRappl FlorianRappl merged commit e361367 into ElectronNET:develop May 1, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants