38 lines
1019 B
Python
38 lines
1019 B
Python
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
|
load("@bazel_gazelle//:def.bzl", "gazelle", "gazelle_binary")
|
|
load("//lib:write_source_files.bzl", "write_source_files")
|
|
|
|
gazelle_binary(
|
|
name = "gazelle_bin",
|
|
languages = ["@bazel_skylib//gazelle/bzl"],
|
|
)
|
|
|
|
gazelle(
|
|
name = "gazelle",
|
|
gazelle = "gazelle_bin",
|
|
)
|
|
|
|
bzl_library(
|
|
name = "internal_deps",
|
|
srcs = ["internal_deps.bzl"],
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"@bazel_tools//tools/build_defs/repo:http.bzl",
|
|
"@bazel_tools//tools/build_defs/repo:utils.bzl",
|
|
],
|
|
)
|
|
|
|
# write_source_files() to a git ignored subdirectory of the root
|
|
genrule(
|
|
name = "write_source_file_root",
|
|
outs = ["write_source_file-root_directory"],
|
|
cmd = "mkdir -p $@ && echo 'test' > $@/test.txt",
|
|
visibility = ["//visibility:private"],
|
|
)
|
|
|
|
write_source_files(
|
|
name = "write_source_file_root-test",
|
|
diff_test = False,
|
|
files = {"test-out/dist/write_source_file_root-test": ":write_source_file_root"},
|
|
)
|