sbt-protoc icon indicating copy to clipboard operation
sbt-protoc copied to clipboard

Document how to add MessageOptions

Open UnaiUribarri-TomTom opened this issue 1 year ago • 1 comments

I need to migrate from old ScalaPB sbt plugin and I cannot find how to translate this:

PB.protoSettings += scalapb.options.Scalapb
  .MessageOptions
  .newBuilder()
  .setExtends("CommonTrait")
  .build()

Can you help me?

UnaiUribarri-TomTom avatar Nov 13 '24 07:11 UnaiUribarri-TomTom

Hi there, I am not sure which sbt plugin you were using - this setting is not familiar for me. However, if you want all generated messages to extend CommonTrait you can use auxiliary options with a target of *.

thesamet avatar Nov 18 '24 01:11 thesamet