3
有人设法成功使用了'ruby protocol buffers' gem? 我在编译基本原型文件的问题:如何使用ruby协议缓冲gem来编译proto文件?
package Test;
message MyMessage
{
optional string myField = 1;
}
当我打电话ruby-protoc test.proto
我收到以下错误信息:
Person.proto:5:3: Expected "required", "optional", or "repeated".
Person.proto:6:3: Expected "required", "optional", or "repeated".
/var/lib/gems/1.9.1/gems/ruby-protocol-buffers-1.4.1/lib/protocol_buffers/compiler.rb:15:in `compile': 1 (ProtocolBuffers::CompileError)
from /var/lib/gems/1.9.1/gems/ruby-protocol-buffers-1.4.1/bin/ruby-protoc:38:in `<top (required)>'
from /usr/local/bin/ruby-protoc:23:in `load'
from /usr/local/bin/ruby-protoc:23:in `<main>'
非常感谢,
托梅克
你有没有想过这一个?我也收到这个错误 –
我手工制作了我的Ruby模块。 – Paul