Closed jarrodldavis closed 5 years ago
I very much like the idea! I wanted to do something similar :) Tests would be great.
@AArnott For these tests, I will need NuGet packages to be generated before test execution starts. Do you want to update your Azure Pipelines configurations to handle that or should I make packing the solution's NuGet packages part of the test arrange phase?
Sorry it's taken slow long to get to this. But I'm super excited at the prospect. I haven't looked at your code change yet.
I will need NuGet packages to be generated before test execution starts. Do you want to update your Azure Pipelines configurations to handle that or should I make packing the solution's NuGet packages part of the test arrange phase?
I would expect all of the build to be done before tests start, including build of packages. This is already in place:
Can you clarify what's missing?
I would expect all of the build to be done before tests start, including build of packages. This is already in place: Can you clarify what's missing?
Ah, I guess I didn't look closely enough at the pipeline config and was going off of my local development experience. That should work.
Sorry it's taken slow long to get to this. But I'm super excited at the prospect. I haven't looked at your code change yet.
That's alright; I've been busy with a number of other things and still need to work on the tests. I'm going to switch to using Buildalyzer since getting the (in-process) Roslyn build setup with Microsoft's NuGet packages is difficult and brittle.
Hi @jarrodldavis
Please join me in designing the SDK approach for this project in #113 (Create SDKs).
I'll close this PR for now, because with #114 (DotNetCorePlugins) on my radar the usage will change drastically (hopefully simplifying a lot of stuff).
Add a new project that creates an MSBuild Project SDK package that can be used to automatically add the required packages and build-time MSBuild targets to the immediately downstream project. The downstream project is also packaged up as an MSBuild Project SDK so that NuGet-packaged code generators can automatically pull in the reference to the generator project.
CodeGeneration.Roslyn
dependencies with a singleFor example, the generator project will look like this:
And projects consuming that generator will look like this:
In both cases, package references,
dotnet
tool references, targets, and properties will be automatically included without additional configuration.Things left to do:
CodeGeneration.Roslyn.Sdk
package in immediately downstream projects (generators)