-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Clean-up generators.targets #82304
Clean-up generators.targets #82304
Conversation
From what I can see, the two targets in generators.targets aren't used anymore. The `LibraryImportGenerator_UseMarshalType` setting was already defined in LibraryImportGenerator.props. Also, remove that props file and inline the values into generators.targets.
Tagging subscribers to this area: @dotnet/runtime-infrastructure Issue DetailsFrom what I can see, the two targets in generators.targets aren't used anymore. The
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have the props file so we have a close relationship between which options the LibraryImportGenerator supports and the MSBuild infrastructure to expose the options. Can we add a comment around the CompilerVisibleProperty
items saying to keep in sync with the OptionsHelper.cs file in LibraryImportGenerator?
Is that the general best practice for libraries generators? I find it nice to have the separate props right next to the generator itself. That way it is easy to see what settings there are for the generator. |
A props file adds value when it is imported by another props file, i.e. Directory.Build.props. It's benefit is questionable if a props file is imported by targets file. That said, I'm fine with keeping it if that's desirable. |
We can create a generators.props file that just includes the props files for generator options if that makes it more worthwhile. |
Closing as this doesn't seem necessary. |
From what I can see, the two targets in generators.targets aren't used anymore. The
LibraryImportGenerator_UseMarshalType
setting was already defined in LibraryImportGenerator.props. Also, remove that props file and inline the values into generators.targets.