Add generation to multiple directories for C# plugin#24426
Add generation to multiple directories for C# plugin#24426rokn wants to merge 1 commit intogrpc:masterfrom
Conversation
|
|
|
The problems with this:
So unless you have very compelling reasons why the "base_namespace" option is really necessary, we won't accept this patch, sorry. |
|
Hey @jtattermusch, sorry for the late reply. Can you elaborate more on why this wouldn't be supported by the Grpc.Tools package? If you have multiple API versions in which there are duplicated files for example: How would you generate them in the correct structure so that there are these files in the gen folder: |
The scenario that you're describing is something that was broken in Grpc.Tools before (see #17672), but we fixed that a while ago: #22869. So when using a new enough version of Grpc.Tools, you basically don't need to anything for this scenario to work correctly. I'm going to close this PR as #17672 is now fixed and we don't really need this anymore. |

I've added an option for the C# plugin to generate nested directories just like the protobuf C# generator.
See here for original issue in protobuf and here for the PR that introduces it in the protobuf repo. I've reused the same helper that is used by the protobuf C# generator for this too. This will allow the two plugins to be more consistent with each other.
@donnadionne