Skip to content

Commit

Permalink
Split up prostgen tests/implementation/examples
Browse files Browse the repository at this point in the history
  • Loading branch information
purkhusid committed Apr 29, 2021
1 parent 6247e31 commit 6b4b7d4
Show file tree
Hide file tree
Showing 362 changed files with 19,082 additions and 2,793 deletions.
10 changes: 10 additions & 0 deletions examples/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
load("@rules_rust//rust:rust.bzl", "rust_analyzer")

rust_analyzer(
name = "rust_analyzer",
targets = [
"//prostgen/basic:common_bin",
"//prostgen/helloworld/greeter_client",
"//prostgen/helloworld/greeter_server",
],
)
9 changes: 9 additions & 0 deletions examples/examples_deps.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,11 @@ load("@examples//hello_sys/raze:crates.bzl", "rules_rust_examples_hello_sys_fetc
load("@rules_foreign_cc//:workspace_definitions.bzl", "rules_foreign_cc_dependencies")
load("@rules_rust//bindgen:repositories.bzl", "rust_bindgen_repositories")
load("@rules_rust//proto:repositories.bzl", "rust_proto_repositories")
load("@rules_rust//proto/prostgen:repositories.bzl", "rust_prostgen_repositories")
load("@rules_rust//rust:repositories.bzl", "rust_repositories", "rust_repository_set")
load("@rules_rust//wasm_bindgen:repositories.bzl", "rust_wasm_bindgen_repositories")
load("@rules_rust//tools/rust_analyzer/raze:crates.bzl", "rules_rust_tools_rust_analyzer_fetch_remote_crates")
load("@examples//prostgen/raze:crates.bzl", "rules_rust_examples_prostgen_fetch_remote_crates")

def deps():
"""Define dependencies for `rules_rust` examples"""
Expand All @@ -21,6 +24,10 @@ def deps():

rust_proto_repositories()

rust_prostgen_repositories()

rules_rust_tools_rust_analyzer_fetch_remote_crates()

# Example of `rust_repository_set`
rust_repository_set(
name = "fake_toolchain_for_test_of_sha256",
Expand All @@ -40,6 +47,8 @@ def deps():

rules_rust_examples_complex_sys_repositories()

rules_rust_examples_prostgen_fetch_remote_crates()

maybe(
http_archive,
name = "libc",
Expand Down
8 changes: 8 additions & 0 deletions examples/prostgen/BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
load("@rules_proto//proto:defs.bzl", "proto_library")

package(default_visibility = ["//prostgen:__subpackages__"])

proto_library(
name = "common",
srcs = ["common.proto"],
)
Loading

0 comments on commit 6b4b7d4

Please sign in to comment.