load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test") go_library( name = "fetch_repo_lib", srcs = [ "fetch_repo.go", "module.go", "vcs.go", ], importpath = "github.com/bazelbuild/bazel-gazelle/cmd/fetch_repo", visibility = ["//visibility:private"], deps = [ "@org_golang_x_mod//sumdb/dirhash", "@org_golang_x_tools_go_vcs//:vcs", ], ) go_binary( name = "fetch_repo", embed = [":fetch_repo_lib"], visibility = ["//visibility:public"], ) go_test( name = "fetch_repo_test", srcs = ["fetch_repo_test.go"], embed = [":fetch_repo_lib"], deps = ["@org_golang_x_tools_go_vcs//:vcs"], ) filegroup( name = "all_files", testonly = True, srcs = [ "BUILD.bazel", "fetch_repo.go", "fetch_repo_test.go", "module.go", "vcs.go", ], visibility = ["//visibility:public"], )