Skip to content

Commit 9444952

Browse files
1 parent 3595a78 commit 9444952

File tree

7 files changed

+175
-1
lines changed

7 files changed

+175
-1
lines changed
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
"aspect-build/bazel-lib"
2+
3+
module(
4+
name = "aspect_bazel_lib",
5+
version = "2.17.0",
6+
bazel_compatibility = [">=6.0.0"],
7+
compatibility_level = 1,
8+
)
9+
10+
# Lower-bounds (minimum) versions for direct runtime dependencies
11+
bazel_dep(name = "bazel_features", version = "1.9.0")
12+
bazel_dep(name = "bazel_skylib", version = "1.5.0")
13+
bazel_dep(name = "platforms", version = "0.0.10")
14+
bazel_dep(name = "stardoc", version = "0.6.2")
15+
bazel_dep(name = "rules_shell", version = "0.4.1")
16+
17+
# TODO(3.0): remove this back-compat
18+
bazel_dep(name = "jq.bzl", version = "0.1.0")
19+
bazel_dep(name = "yq.bzl", version = "0.1.1")
20+
bazel_dep(name = "tar.bzl", version = "0.2.1")
21+
22+
bazel_lib_toolchains = use_extension("@aspect_bazel_lib//lib:extensions.bzl", "toolchains")
23+
bazel_lib_toolchains.copy_directory()
24+
bazel_lib_toolchains.copy_to_directory()
25+
bazel_lib_toolchains.jq()
26+
bazel_lib_toolchains.yq()
27+
bazel_lib_toolchains.coreutils()
28+
bazel_lib_toolchains.tar()
29+
bazel_lib_toolchains.zstd()
30+
bazel_lib_toolchains.expand_template()
31+
bazel_lib_toolchains.bats()
32+
use_repo(bazel_lib_toolchains, "bats_toolchains", "bsd_tar_toolchains", "copy_directory_toolchains", "copy_to_directory_toolchains", "coreutils_toolchains", "expand_template_toolchains", "jq", "jq_toolchains", "yq", "yq_toolchains", "zstd_toolchains")
33+
34+
register_toolchains(
35+
"@copy_directory_toolchains//:all",
36+
"@copy_to_directory_toolchains//:all",
37+
"@jq_toolchains//:all",
38+
"@yq_toolchains//:all",
39+
"@coreutils_toolchains//:all",
40+
"@expand_template_toolchains//:all",
41+
"@bats_toolchains//:all",
42+
"@bsd_tar_toolchains//:all",
43+
"@zstd_toolchains//:all",
44+
)
45+
46+
####### Dev dependencies ########
47+
48+
# To allow /tools to be built from source
49+
# NOTE: when publishing to BCR, we patch this to be dev_dependency, as we publish pre-built binaries
50+
# along with our releases.
51+
52+
bazel_dep(
53+
name = "gazelle",
54+
version = "0.40.0",
55+
dev_dependency = True,
56+
)
57+
bazel_dep(
58+
name = "rules_go",
59+
version = "0.51.0",
60+
repo_name = "io_bazel_rules_go",
61+
dev_dependency = True,
62+
)
63+
64+
go_deps = use_extension(
65+
"@gazelle//:extensions.bzl",
66+
"go_deps",
67+
dev_dependency = True,
68+
)
69+
go_deps.from_file(go_mod = "//:go.mod")
70+
use_repo(
71+
go_deps,
72+
"com_github_bmatcuk_doublestar_v4",
73+
"org_golang_x_exp",
74+
"org_golang_x_sys",
75+
)
76+
77+
host = use_extension("@aspect_bazel_lib//lib:extensions.bzl", "host", dev_dependency = True)
78+
host.host()
79+
use_repo(host, "aspect_bazel_lib_host")
80+
81+
host_platform = use_extension("@platforms//host:extension.bzl", "host_platform")
82+
use_repo(host_platform, "host_platform")
83+
84+
bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.5.0", dev_dependency = True)
85+
bazel_dep(name = "buildifier_prebuilt", version = "6.4.0", dev_dependency = True)
86+
bazel_dep(name = "external_test_repo", version = "0.0.0", dev_dependency = True)
87+
local_path_override(
88+
module_name = "external_test_repo",
89+
path = "./lib/tests/external_test_repo",
90+
)
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"mediaType": "application/vnd.build.bazel.registry.attestation+json;version=1.0.0",
3+
"attestations": {
4+
"source.json": {
5+
"url": "https://github.com/bazel-contrib/bazel-lib/releases/download/v2.17.0/source.json.intoto.jsonl",
6+
"integrity": "sha256-RThblLLlWGuseC+17jwanOFjNDwmuERNL2Wmrd6bbv4="
7+
},
8+
"MODULE.bazel": {
9+
"url": "https://github.com/bazel-contrib/bazel-lib/releases/download/v2.17.0/MODULE.bazel.intoto.jsonl",
10+
"integrity": "sha256-ntdlV7FYIvpLbI+IkI2gIQ6PJxK3l5FMYER79Tg7Vxg="
11+
},
12+
"bazel-lib-v2.17.0.tar.gz": {
13+
"url": "https://github.com/bazel-contrib/bazel-lib/releases/download/v2.17.0/bazel-lib-v2.17.0.tar.gz.intoto.jsonl",
14+
"integrity": "sha256-p/zXRPkSEz6rtr31HVWIeQYccL2Ec9vhDP351IEOO6M="
15+
}
16+
}
17+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
diff --git a/MODULE.bazel b/MODULE.bazel
2+
index e63fa5b..9d78a88 100644
3+
--- a/MODULE.bazel
4+
+++ b/MODULE.bazel
5+
@@ -50,19 +50,19 @@ use_repo(host, "aspect_bazel_lib_host")
6+
bazel_dep(
7+
name = "gazelle",
8+
version = "0.40.0",
9+
- # In released versions: dev_dependency = True
10+
+ dev_dependency = True,
11+
)
12+
bazel_dep(
13+
name = "rules_go",
14+
version = "0.51.0",
15+
repo_name = "io_bazel_rules_go",
16+
- # In released versions: dev_dependency = True
17+
+ dev_dependency = True,
18+
)
19+
20+
go_deps = use_extension(
21+
"@gazelle//:extensions.bzl",
22+
"go_deps",
23+
- # In released versions: dev_dependency = True
24+
+ dev_dependency = True,
25+
)
26+
go_deps.from_file(go_mod = "//:go.mod")
27+
use_repo(
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
===================================================================
2+
--- a/MODULE.bazel
3+
+++ b/MODULE.bazel
4+
@@ -1,9 +1,9 @@
5+
"aspect-build/bazel-lib"
6+
7+
module(
8+
name = "aspect_bazel_lib",
9+
- version = "0.0.0",
10+
+ version = "2.17.0",
11+
bazel_compatibility = [">=6.0.0"],
12+
compatibility_level = 1,
13+
)
14+
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
bcr_test_module:
2+
module_path: "e2e/smoke"
3+
matrix:
4+
platform: ["debian10", "macos", "ubuntu2004", "windows"]
5+
bazel:
6+
- 6.x
7+
- 7.x
8+
- 8.x
9+
tasks:
10+
run_tests:
11+
name: "Run test module"
12+
platform: ${{ platform }}
13+
bazel: ${{ bazel }}
14+
test_targets:
15+
- "//..."
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"integrity": "sha256-WrwXm+a+2t9CK+WYwa+RjH67iixd+ubTGevm7F2+yGo=",
3+
"strip_prefix": "bazel-lib-2.17.0",
4+
"url": "https://github.com/bazel-contrib/bazel-lib/releases/download/v2.17.0/bazel-lib-v2.17.0.tar.gz",
5+
"patches": {
6+
"go_dev_dep.patch": "sha256-VisWDx/BkcKul0/HXaEq9LKcjRxMCZG4QJni2rAfI/Q=",
7+
"module_dot_bazel_version.patch": "sha256-VBliyP9aGLDSw41exZ1Uk3WznvfLH00YzOokcFggCqQ="
8+
},
9+
"patch_strip": 1
10+
}

modules/aspect_bazel_lib/metadata.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,8 @@
147147
"2.13.0",
148148
"2.14.0",
149149
"2.15.3",
150-
"2.16.0"
150+
"2.16.0",
151+
"2.17.0"
151152
],
152153
"yanked_versions": {
153154
"1.31.0": "1.31.0 has a breaking change to the default yq version",

0 commit comments

Comments
 (0)