Skip to content

Commit 3e7ee3e

Browse files
committed
chore: README.md section for scala_proto_toolchain changes
1 parent 3dac61c commit 3e7ee3e

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -813,6 +813,35 @@ under `WORKSPACE`](#6.5.0), with the maximum dependency versions specified in
813813
that section. While this may continue to work for some time, it is not
814814
officially supported.
815815

816+
### `scala_proto_toolchain` changes
817+
818+
Since #1718 `scala_proto_toolchain`'s `main_generator` was removed in flavor of more
819+
flexible protobuf plugins configuration. Now each generator (plugin) will get a corresponding name
820+
that can be used for further plugin options setup:
821+
822+
```
823+
scala_proto_toolchain(
824+
name = "example",
825+
generators_opts = {
826+
"scala": [
827+
"grpc",
828+
"single_line_to_proto_string",
829+
],
830+
"jvm_extra_protobuf_generator": [
831+
"grpc",
832+
"single_line_to_proto_string",
833+
],
834+
},
835+
generators = {
836+
"scala": "scripts.ScalaPbCodeGenerator",
837+
"jvm_extra_protobuf_generator": "scalarules.test.extra_protobuf_generator.ExtraProtobufGenerator",
838+
},
839+
)
840+
```
841+
842+
Also, `scalapb_grpc_deps` was removed since this changes moves the responsibility
843+
on the user side to configure dependencies based on the provided generators and their options.
844+
816845
### Bazel module compatibility levels
817846

818847
`rules_scala` 7.0.0 will set the

0 commit comments

Comments
 (0)