Skip to content

Instantly share code, notes, and snippets.

@zroger
Last active December 12, 2015 08:48
Show Gist options
  • Save zroger/4746387 to your computer and use it in GitHub Desktop.
Save zroger/4746387 to your computer and use it in GitHub Desktop.
### Generated by rprotoc. DO NOT EDIT!
### <proto file: test/proto/addressbook_ext.proto>
# import "test/proto/addressbook_base.proto";
# package tutorial_ext;
#
# extend Person {
# optional int32 age = 100;
# }
require 'protobuf/message/message'
require 'protobuf/message/enum'
require 'protobuf/message/extend'
require 'test/proto/addressbook_base.pb'
module TutorialExt
class Person < ::Protobuf::Message
defined_in __FILE__
optional :int32, :age, 100, :extension => true
end
end
cd ~/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/protobuf-2.6.4
mkdir tmp
rprotoc --ruby_out=tmp test/proto/addressbook*.proto
diff test/proto/addressbook_ext.pb.rb tmp/test/proto/addressbook_ext.pb.rb
##
# This file is auto-generated. DO NOT EDIT!
#
##
# Imports
#
require 'test/proto/addressbook_base.pb'
module Tutorial_Ext
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment