.proto files not picked up when not in src/main/protobuf
Closed this issue · 1 comments
rabejens commented
I have this in my build.sbt
:
Compile / PB.targets := Seq(
PB.gens.java("3.24.1") -> (Compile / sourceManaged).value,
PB.gens.plugin("grpc-java") -> (Compile / sourceManaged).value
)
Compile / PB.protoSources := Seq(
baseDirectory.value / "external" / "Protos",
baseDirectory.value / "external" / "MyOtherFolder" / "Protos"
)
The .proto
files are not picked up.
However, when I move the contents of the two Protos
folders into src/main/protobuf
and remove the PB.protoSources
section, they are picked up and compiled.
What am I missing?
rabejens commented
Turned out that my paths were wrong.
This is the correct setting which works:
Compile / PB.protoSources := Seq(
baseDirectory.value / "external" / "myProject" / "Protos",
baseDirectory.value / "external" / "myProject" / "MyOtherFolder" / "Protos"
)