BUILD 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. load(
  2. "@io_bazel_rules_go//proto:def.bzl",
  3. "go_proto_library",
  4. )
  5. package(default_visibility = ["//visibility:public"])
  6. load(
  7. "@io_bazel_rules_go//go:def.bzl",
  8. "go_library",
  9. )
  10. proto_library(
  11. name = "model_proto",
  12. srcs = ["message.proto"],
  13. tags = ["automanaged"],
  14. deps = ["@gogo_special_proto//github.com/gogo/protobuf/gogoproto"],
  15. )
  16. go_proto_library(
  17. name = "model_go_proto",
  18. compilers = ["@io_bazel_rules_go//proto:gogofast_proto"],
  19. importpath = "go-common/app/service/main/up/model",
  20. proto = ":model_proto",
  21. tags = ["automanaged"],
  22. deps = [
  23. "//library/time:go_default_library",
  24. "@com_github_gogo_protobuf//gogoproto:go_default_library",
  25. ],
  26. )
  27. go_library(
  28. name = "go_default_library",
  29. srcs = [
  30. "archive.go",
  31. "monitor.go",
  32. "msg.go",
  33. "rpc.go",
  34. "sign_up.go",
  35. "up.go",
  36. "up_card.go",
  37. "up_group.go",
  38. "up_info.go",
  39. "up_special.go",
  40. "up_switch.go",
  41. ],
  42. embed = [":model_go_proto"],
  43. importpath = "go-common/app/service/main/up/model",
  44. tags = ["automanaged"],
  45. visibility = ["//visibility:public"],
  46. deps = [
  47. "//library/time:go_default_library",
  48. "//vendor/github.com/siddontang/go-mysql/mysql:go_default_library",
  49. "@com_github_gogo_protobuf//gogoproto:go_default_library",
  50. "@com_github_golang_protobuf//proto:go_default_library",
  51. ],
  52. )
  53. filegroup(
  54. name = "package-srcs",
  55. srcs = glob(["**"]),
  56. tags = ["automanaged"],
  57. visibility = ["//visibility:private"],
  58. )
  59. filegroup(
  60. name = "all-srcs",
  61. srcs = [
  62. ":package-srcs",
  63. "//app/service/main/up/model/data:all-srcs",
  64. ],
  65. tags = ["automanaged"],
  66. visibility = ["//visibility:public"],
  67. )