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