0
Fork 0
mirror of https://github.com/project-zot/zot.git synced 2024-12-16 21:56:37 -05:00
zot/BUILD.bazel

101 lines
2.6 KiB
Text
Raw Normal View History

2019-06-20 18:36:40 -05:00
# Disable build files generation for these directories
# gazelle:exclude vendor/github.com/bazelbuild/buildtools/buildifier2
# gazelle:exclude vendor/golang.org/x/tools/cmd/fiximports/testdata
# gazelle:exclude vendor/golang.org/x/tools/go/gcimporter15/testdata
# gazelle:exclude vendor/golang.org/x/tools/go/internal/gccgoimporter/testdata
# gazelle:exclude vendor/golang.org/x/tools/go/loader/testdata
# gazelle:exclude vendor/golang.org/x/tools/go/internal/gcimporter/testdata
# gazelle:resolve proto go github.com/grpc-ecosystem/grpc-gateway/internal //internal:go_default_library
# gazelle:proto disable_global
load("@bazel_gazelle//:def.bzl", "gazelle")
load("@com_github_atlassian_bazel_tools//buildozer:def.bzl", "buildozer")
load("@com_github_atlassian_bazel_tools//goimports:def.bzl", "goimports")
load("@com_github_atlassian_bazel_tools//golangcilint:def.bzl", "golangcilint")
load("@com_github_bazelbuild_buildtools//buildifier:def.bzl", "buildifier")
load("@io_bazel_rules_go//go:def.bzl", "go_library", "nogo")
gazelle(
name = "gazelle",
build_tags = ["jsoniter"],
external = "external",
extra_args = ["-exclude=vendor"],
gazelle = "@bazel_gazelle//cmd/gazelle:gazelle_pure",
prefix = "github.com/anuvu/zot",
)
gazelle(
name = "gazelle_fix",
build_tags = ["jsoniter"],
command = "fix",
external = "external",
extra_args = ["-exclude=vendor"],
gazelle = "@bazel_gazelle//cmd/gazelle:gazelle_pure",
prefix = "github.com/anuvu/zot",
)
buildifier(
name = "buildifier",
exclude_patterns = ["./vendor/*"],
)
buildifier(
name = "buildifier_check",
exclude_patterns = ["./vendor/*"],
mode = "check",
)
buildifier(
name = "buildifier_fix",
lint_mode = "fix",
)
buildozer(
name = "buildozer",
commands = ".bazel/buildozer_commands.txt",
)
goimports(
name = "goimports",
display_diffs = True,
exclude_files = [
"zz_generated.*",
],
exclude_paths = [
"./vendor/*",
],
prefix = "github.com/anuvu/zot",
write = True,
)
golangcilint(
name = "golangcilint",
config = ".bazel/golangcilint.yaml",
paths = [
"./...",
],
prefix = "github.com/anuvu/zot",
)
nogo(
name = "nogo",
config = ".bazel/nogo-config.json",
vet = True,
visibility = ["//visibility:public"],
)
go_library(
name = "go_default_library",
srcs = ["zot.go"],
importpath = "github.com/anuvu/zot",
visibility = ["//visibility:public"],
)
filegroup(
name = "exported_testdata",
srcs = glob([
"test/data/*",
]),
visibility = ["//visibility:public"],
)