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

Target NetStandard to support .NET Core #10

Closed
FlorianHockmann opened this issue May 4, 2017 · 16 comments
Closed

Target NetStandard to support .NET Core #10

FlorianHockmann opened this issue May 4, 2017 · 16 comments

Comments

@FlorianHockmann
Copy link

Could you add NetStandard as a target framework so that Cake.Docker can be used with .NET Core? Note also that there seem to be plans to deprecate Mono in Cake.

@MihaMarkic
Copy link
Owner

You mean in nuspec? I have to check out what exactly works. But yes, the idea certainly a good one.

@FlorianHockmann
Copy link
Author

I think that you have to specify the target frameworks in the project file. The best option is probably to upgrade to the new csproj format which makes it really easy to target multiple frameworks. This article from Microsoft explains how an existing project that only targets .NET Framework can be upgraded to also target .NET Core. In the end, you have a csproj file that looks something like this.

@MihaMarkic
Copy link
Owner

@FlorianHockmann Yes, I know. I'm just trying to understand the Cake's support for .NET Core.

@secana
Copy link

secana commented May 7, 2017

Support for NetStandard would be really useful. So a big +1 from my site for this issue.

@MihaMarkic
Copy link
Owner

I'm certainly looking into this. Anybody knows of a Cake addin that supports .NET Standard?

@FlorianHockmann
Copy link
Author

Cake.Npm seems to support it in addition to .NET Framework 4.5 and 4.6.

@MihaMarkic
Copy link
Owner

Looking at Cake.Npm. It references just (non-net standard) Cake.Core. I wonder whether it works fine with Cake.CoreCLR.

@MihaMarkic
Copy link
Owner

@secana @FlorianHockmann Can you guys give it a spin with .NET Standard/Core?

You'll find it (for testing) on myget at
#addin nuget:https://www.myget.org/f/righthand-test/?package=Cake.Docker

Version is 0.7.7.

@secana
Copy link

secana commented Jun 6, 2017

@MihaMarkic @FlorianHockmann I'll start testing the package this week. As soon as I've some results I'll share my feedback here

@secana
Copy link

secana commented Jun 6, 2017

@MihaMarkic Could you provide an download link for the package? Under Linux it's not possible to use #addin nuget:... because there is only the very old mono nuget binary. I would download the package by hand in that case. In the NuGet gallery there's a download link but I cannot find something similar for MyGet.

@secana
Copy link

secana commented Jun 6, 2017

I've tested DockerBuild under Linux in a Cake script and it works with netstandard and .net core. Pretty cool. I'll test a few more things and report back.

@secana
Copy link

secana commented Jun 7, 2017

One small thing: Your DockerPush* classes are in the folder Pull and the DockerPull* classes are in the folder Push

I guess that's not the way it was meant to be

@secana
Copy link

secana commented Jun 7, 2017

Summary: I've tested the basic docker stuff and everything works fine with .Net Core

I would say you can publish the new version to NuGet. Regards, secana

@MihaMarkic
Copy link
Owner

@secana, thank you very much. I'll check about that folders mismatch.

@secana
Copy link

secana commented Jun 9, 2017

@MihaMarkic Could you please upload the 0.7.7 to the NuGet gallery? We could start using it then in our build scripts which would be a great help.
Regards, secana

@MihaMarkic
Copy link
Owner

Uploaded 0.7.7 to NuGet.org. Thanks @FlorianHockmann and @secana for testing, suggestion and help.

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

No branches or pull requests

3 participants