Add C# plugin "file_suffix" option defaulting to "Grpc.cs"#26162
Add C# plugin "file_suffix" option defaulting to "Grpc.cs"#26162jtattermusch merged 3 commits intogrpc:masterfrom
Conversation
jskeet
left a comment
There was a problem hiding this comment.
This is great, thanks.
So just to check, if I want to just change the extension to .g.cs, I'd set --grpc_opts=file_extension=Grpc.g.cs, yes?
|
(Would it possibly make sense to call it |
Yes. |
Yes, I was thinking that as well. On the other hand, then protoc and grpc_csharp_ext would have different names for an analogous option (but one that isn't quite identical). I'm not sure which one's better. |
|
I updated the option name to "file_suffix" to avoid confusion. |
Fixes #26056
note that in the current version of this PR, the
file_suffixoption's default value is actually "Grpc.cs" (but I thought that configuring the "Grpc" suffix might be useful as well).IMPORTANT: This option should only be used with "manual" invocations of protoc from a shell script. The Grpc.Tools integration won't support this option since it relies on "guessing" the exact name of the generated files produced by protoc.