2
0
Fork 0
mirror of https://github.com/bazelbuild/bazel-skylib synced 2024-11-28 08:43:51 +00:00
bazel-skylib/BUILD
nickgooding 31ab4c8bd2
feat: bzlmod setup (#385)
Creates MODULE.bazel and WORKSPACE.bzlmod files to enable bazel-skylib
to work with the `--experimental_enable_bzlmod` flag.

rules_go has been updated as the previously used version is not
available in the BCR.

stardoc has been updated due to a strange issue with Bzlmod enabled that
caused the `diff_test` and `unittest` docs to be generated without any
contents that was magically fixed upon updating.

bazelbuild/bazel-central-registry#124

Co-authored-by: Alexandre Rostovtsev <arostovtsev@google.com>
2022-08-30 14:57:34 -04:00

82 lines
1.7 KiB
Python

load("//:bzl_library.bzl", "bzl_library")
licenses(["notice"])
package(default_visibility = ["//visibility:public"])
# buildifier: disable=skylark-comment
# gazelle:exclude skylark_library.bzl
exports_files([
"LICENSE",
"MODULE.bazel",
])
filegroup(
name = "test_deps",
testonly = True,
srcs = [
"BUILD",
"//lib:test_deps",
"//rules:test_deps",
"//toolchains/unittest:test_deps",
] + glob(["*.bzl"]),
)
bzl_library(
name = "lib",
srcs = ["lib.bzl"],
deprecation = (
"lib.bzl will go away in the future, please directly depend on the" +
" module(s) needed as it is more efficient."
),
deps = [
"//lib:collections",
"//lib:dicts",
"//lib:new_sets",
"//lib:partial",
"//lib:paths",
"//lib:selects",
"//lib:sets",
"//lib:shell",
"//lib:structs",
"//lib:types",
"//lib:unittest",
"//lib:versions",
],
)
bzl_library(
name = "bzl_library",
srcs = ["bzl_library.bzl"],
)
bzl_library(
name = "version",
srcs = ["version.bzl"],
)
bzl_library(
name = "workspace",
srcs = ["workspace.bzl"],
)
# The files needed for distribution.
# TODO(aiuto): We should strip this from the release, but there is no
# capability now to generate BUILD.foo from BUILD and have it appear in the
# tarball as BUILD.
filegroup(
name = "distribution",
srcs = [
"LICENSE",
"BUILD",
"CODEOWNERS",
"CONTRIBUTORS",
"WORKSPACE.bzlmod",
"//lib:distribution",
"//rules:distribution",
"//rules/private:distribution",
"//toolchains/unittest:distribution",
] + glob(["*.bzl"]),
)