github.com/stackb/rules_proto@v0.0.0-20240221195024-5428336c51f1/example/golden/testdata/scala/WORKSPACE (about) 1 # ---------------------------------------------------- 2 # scala 3 # ---------------------------------------------------- 4 5 load("@build_stack_rules_proto//deps:scala_deps.bzl", "scala_deps") 6 7 scala_deps() 8 9 load("@io_bazel_rules_scala//:scala_config.bzl", "scala_config") 10 11 scala_config(scala_version = "2.12.18") 12 13 load("@io_bazel_rules_scala//scala:scala.bzl", "scala_repositories") 14 15 scala_repositories() 16 17 load("@io_bazel_rules_scala//scala:toolchains.bzl", "scala_register_toolchains") 18 19 scala_register_toolchains() 20 21 # ---------------------------------------------------- 22 # maven 23 # ---------------------------------------------------- 24 25 load( 26 "@rules_jvm_external//:defs.bzl", 27 "maven_install", 28 ) 29 30 maven_install( 31 name = "maven_scala", 32 artifacts = [ 33 "com.thesamet.scalapb:lenses_2.12:0.11.10", 34 "com.thesamet.scalapb:scalapb-json4s_2.12:0.12.0", 35 "com.thesamet.scalapb:scalapb-runtime_2.12:0.11.10", 36 "com.thesamet.scalapb:scalapb-runtime-grpc_2.12:0.11.10", 37 "com.thesamet.scalapb:scalapbc_2.12:0.11.10", 38 "org.json4s:json4s-core_2.12:4.0.3", 39 ], 40 fetch_sources = True, 41 repositories = ["https://repo1.maven.org/maven2"], 42 ) 43 44 # ---------------------------------------------------- 45 # akka 46 # ---------------------------------------------------- 47 48 maven_install( 49 name = "maven_akka", 50 artifacts = [ 51 "com.lightbend.akka.grpc:akka-grpc-codegen_2.12:2.1.3", 52 "com.lightbend.akka.grpc:akka-grpc-runtime_2.12:2.1.3", 53 ], 54 fetch_sources = True, 55 repositories = ["https://repo1.maven.org/maven2"], 56 ) 57 58 # ---------------------------------------------------- 59 # proto_repository 60 # ---------------------------------------------------- 61 62 load("@build_stack_rules_proto//rules/proto:proto_repository.bzl", "proto_repository") 63 64 proto_repository( 65 name = "scalaapis", 66 build_directives = ["gazelle:proto_language scala enabled true"], 67 build_file_generation = "on", 68 build_file_proto_mode = "file", 69 cfgs = ["//:config.yaml"], 70 sha256 = "1ac039f79b0825fe2e7e5ddf24e330632d63b70a7a42bfd39ded5bb1fb648811", 71 # the typical importpath is 'scalapb/scalapb.proto', so strip the prefix up 72 # to that directory. 73 strip_prefix = "ScalaPB-a4e0e02c0f5b160877d5f97f6902dbec4c633afe/protobuf", 74 type = "zip", 75 urls = ["https://codeload.github.com/scalapb/ScalaPB/zip/a4e0e02c0f5b160877d5f97f6902dbec4c633afe"], 76 )