-
Notifications
You must be signed in to change notification settings - Fork 59
Create SDK package #113
Comments
No, I don't think so. VS has an implementation detail that depends on that property being set within the project file itself. Otherwise it'll load the project with the wrong project system in some cases. |
Ahh yes, hacks and details. Besides Will keep that in mind. Maybe a check with warning then. So, other than that, any suggestions? I'm very much not happy with names. All of them sound weird. Especially the possible |
I think I remember running into that issue when initially trying to package up a generator and part of what led to my (admittedly convoluted) double-SDK solution in my pull request (#108). Edit: yes I remember after a lot of spelunking through NuGet issues finding stuff like NuGet/Home#4013 and NuGet/Home#3604 where the NuGet team specifically prevented recursive package restores to prevent various issues. |
No other suggestions at this point.
How about CG.R.Generator.Sdk? |
* Engine uses `McMaster.NETCore.Plugins` package to resolve assemblies and dependencies, enabling generators to reference additional dependencies! 🎉 * Tasks deprecate `GeneratorAssemblySearchPaths` usage * Tasks use `CodeGenerationRoslynPlugin` ItemGroup instead, which contains concrete assembly paths (instead of containing folder paths, as was previously) * Engine targets `netcoreapp2.0` to reference McMaster package * Tests use Amadevus.RecordGenerator NuGet generator for back-compat checks * Tests.Generators use Bogus NuGet for NuGet dependency resolution check * `CodeGeneration.Roslyn.Plugin.Sdk` MSBuild project Sdk created, to help build and package plugins correctly. * Migrate to use VS2019/.NET Core SDK v3.1 * Rewritten Readme with a simpler demo and more advanced scenarios * Change input assemblies check Now the list of plugin assemblies is always read from response file (plugin list), the last modified time is calculated using those assemblies, and the .AssemblyList.txt file is not created. Also separated reading the results into another target, and set Inputs and Outputs so that the MSBuild can fully skip executing the target that invokes CLI tool. * Rename BuildTime targets private items * add comment to BuildTime targets * feature: create Plugin.Sdk project initial idea in #113 * fix GenerateCodeFromAttributesCore condition _CodeGenToolVersionExitCode was compared to zero via != instead of == * fix CGR1002 warning in Tests * refactor and cleanup BuildTime files * refactor Tests project file * docs: readme demo and more for new Plugins.Sdk * don't prefer shared types, use explicit list this will allow different plugins to have conflicting dependencies * refactor: rename dictionary to cachedPlugins * fix: Use OutputItemType in Sample * docs: Add changelog for plugins PR
A rewrite of the Plugin.Sdk is happening at #198. |
Please make it in addition to it. There can only be one top-level SDK, so if too many cool features want to be "the one", a project can't use more than one of them. |
It's done as such. I'm also going to make it usable as a normal When used as a normal package, all props and targets will be the same, except there'll be no implicit |
Summary
The SDK package would be used instead of the
Microsoft.NET.Sdk
Sdk by default, or in addition to it:Inspired by PR #108 by @jarrodldavis
Problems solved
Features
A project built with this SDK would:
provide preset TargetFrameworksee first commentbuild/package-name.props
that include required additions (https://github.com/AArnott/CodeGeneration.Roslyn/blob/d8afd59f1698b45549cd0e7850a645629677fb6f/README.md#packaging-up-your-code-generator-for-others-use)IsTool
,DevelopmentDependency
andNoPackageAnalysis
totrue
And possibly other needed additions.
Additional ideas
It's possible that there would be additional SDKs (just ideas):
global.json
.The text was updated successfully, but these errors were encountered: