diff --git a/bazel/versions.bzl b/bazel/versions.bzl index bb79e235..472c5dbd 100644 --- a/bazel/versions.bzl +++ b/bazel/versions.bzl @@ -1,8 +1,6 @@ - VERSIONS = { "go": "1.23.1", "python": "3.12", - "io_bazel_rules_go": { "type": "github_archive", "repo": "bazelbuild/rules_go", @@ -10,7 +8,6 @@ VERSIONS = { "sha256": "b78f77458e77162f45b4564d6b20b6f92f56431ed59eaaab09e7819d1d850313", "url": "https://github.com/bazelbuild/rules_go/releases/download/v{version}/rules_go-v{version}.zip", }, - "rules_pkg": { "type": "github_archive", "repo": "bazelbuild/rules_pkg", @@ -18,7 +15,6 @@ VERSIONS = { "sha256": "b7215c636f22c1849f1c3142c72f4b954bb12bb8dcf3cbe229ae6e69cc6479db", "url": "https://github.com/bazelbuild/rules_pkg/releases/download/{version}/rules_pkg-{version}.tar.gz", }, - "rules_python": { "type": "github_archive", "repo": "bazelbuild/rules_python", @@ -27,5 +23,12 @@ VERSIONS = { "url": "https://github.com/{repo}/releases/download/{version}/{name}-{version}.tar.gz", "strip_prefix": "{name}-{version}", }, - + "rules_shell": { + "type": "github_archive", + "repo": "bazelbuild/rules_shell", + "version": "0.6.1", + "sha256": "e6b87c89bd0b27039e3af2c5da01147452f240f75d505f5b6880874f31036307", + "url": "https://github.com/{repo}/releases/download/v{version}/{name}-v{version}.tar.gz", + "strip_prefix": "{name}-{version}", + }, } diff --git a/examples.bzl b/examples.bzl index d54de6fd..d2d8b97f 100644 --- a/examples.bzl +++ b/examples.bzl @@ -1,7 +1,6 @@ - +load("@rules_shell//shell:sh_binary.bzl", "sh_binary") def envoy_example(name, shared = ":shared_files", common_fun = ":verify-common.sh"): - native.filegroup( name = "%s_files" % name, srcs = native.glob(["%s/**/*" % name]), @@ -32,7 +31,7 @@ def envoy_example(name, shared = ":shared_files", common_fun = ":verify-common.s ], ) - native.sh_binary( + sh_binary( name = "verify_%s" % name, srcs = [":verify_example.sh"], args = [ @@ -50,7 +49,7 @@ def envoy_examples(examples): name = "shared_files", srcs = native.glob( ["shared/**/*"], - exclude=[ + exclude = [ "**/*~", "**/.*", "**/#*", @@ -75,7 +74,7 @@ def envoy_examples(examples): RESULTS.append("%s_result" % example) RESULT_FILES.append("$(location %s)" % ("%s_result" % example)) - native.sh_binary( + sh_binary( name = "verify_examples", srcs = [":verify_examples.sh"], args = RESULT_FILES,