Skip to content

Commit

Permalink
chore: add rules_buf
Browse files Browse the repository at this point in the history
it comes from aspect-forks until bufbuild/rules_buf#42 is merged, hopefully for the next release
  • Loading branch information
alexeagle committed Oct 11, 2023
1 parent cea9064 commit 19a6ef2
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 0 deletions.
16 changes: 16 additions & 0 deletions modules/rules_buf/0.1.1/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
"Bazel module definition for bzlmod"
module(
name = "rules_buf",
version = "0.1.1", # Replaced when publishing
compatibility_level = 1,
)

bazel_dep(name = "platforms", version = "0.0.4")
# Only needed because rules_proto doesn't provide the protoc toolchain yet.
# TODO(alex/sahin): remove in the future
bazel_dep(name = "protobuf", version = "21.7", repo_name = "com_google_protobuf")
bazel_dep(name = "rules_proto", version = "5.3.0-21.7")

ext = use_extension("//buf:extensions.bzl", "ext")
use_repo(ext, "rules_buf_toolchains")
register_toolchains("@rules_buf_toolchains//:all")
12 changes: 12 additions & 0 deletions modules/rules_buf/0.1.1/patches/module_dot_bazel_version.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
diff --git a/MODULE.bazel b/MODULE.bazel
index 973e2ba..32942a5 100644
--- a/MODULE.bazel
+++ b/MODULE.bazel
@@ -1,7 +1,7 @@
"Bazel module definition for bzlmod"
module(
name = "rules_buf",
- version = "0.0.0", # Replaced when publishing
+ version = "0.1.1", # Replaced when publishing
compatibility_level = 1,
)
10 changes: 10 additions & 0 deletions modules/rules_buf/0.1.1/presubmit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
bcr_test_module:
module_path: 'examples/bzlmod'
matrix:
platform: ['ubuntu2004']
tasks:
run_tests:
name: 'Run test module'
platform: ${{ platform }}
test_targets:
- '//...'
9 changes: 9 additions & 0 deletions modules/rules_buf/0.1.1/source.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"integrity": "sha256-CjfiYuajROyN2Cu4mYd+aY6zCNziwig8DFx/fUH+Cqw=",
"strip_prefix": "rules_buf-99af4b12716531021b9160fa2c622df4c5e8a0de",
"patch_strip": 1,
"patches": {
"module_dot_bazel_version.patch": "sha256-4rf0fU4XVGXhDXfLEqjz/KoOP2wnq/KRW+Ec6k0z5EU="
},
"url": "https://github.com/aspect-forks/rules_buf/archive/99af4b12716531021b9160fa2c622df4c5e8a0de.zip"
}
17 changes: 17 additions & 0 deletions modules/rules_buf/metadata.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"homepage": "https://github.com/bufbuild/rules_buf",
"maintainers": [
{
"email": "alex@aspect.dev",
"github": "alexeagle",
"name": "Alex Eagle"
}
],
"repository": [
"github:aspect-forks/rules_buf"
],
"versions": [
"0.1.1"
],
"yanked_versions": {}
}

0 comments on commit 19a6ef2

Please sign in to comment.