ProtobufGenerator
ProtobufGenerator copied to clipboard
Fails with multiple dependent proto files.
Protoc can "import" multiple .proto files, such that you can divide up your definition like so: Enum.proto and Messages.proto imports the enums defined in Enums.proto. This tool requires a single .proto file.
The protoc docs claims that by default it looks in the directory where protoc is invoked for any imported files. So it SHOULD work in that case (can not test it right now). Imports from a different directory is not supported by this tool, thou it is not very hard to get that to work. There is just a small amount of parsing of the proto file required in order to generate the correct directory parameters for the call to protoc.
I get : Error Unspecified error (Exception from HRESULT: 0x80004005 (E_FAIL)) gRpcProto ...Protos\Messages.proto 1
when I add a 2nd .proto that is dependent upon a first. No .cs files are generated for the 2nd .proto.works fine w/ command line to protoc.exe
Ok, thanks. I have updated the readme in the meantime to inform of this until this is fixed.