Skip to content

v0.26.0

Pre-release
Pre-release
Compare
Choose a tag to compare
@jayconrod jayconrod released this 08 Mar 20:39
ddc5747

Changes

  • //go:embed directives are supported in Go 1.16. Patterns are matched against both static and generated files, including directory artifacts. Embeddable files must be listed in the new embedsrcs attribute. Gazelle v0.23.0 will generate these attributes automatically.
  • go_binary now provides CcInfo in the c-archive and c-shared link modes. This should let cc_library and other rules reference these targets through deps directly. Thanks @steeve.
  • TEST_TMPDIR is no longer set to TMPDIR in tests. Thanks @mikedanese.
  • Several small improvements in error and diagnostic output.

Compatibility

  • Bazel 3.5.0 is now required. The previous minimum version was 3.4.0.

Updated dependencies

As always, you can use higher versions of rules_go's dependencies by declaring them in WORKSPACE before calling go_rules_dependencies. Lower versions may work but are not supported.

  • platforms is updated to 0.0.4.
  • rules_cc is updated to master as of 2021-03-05.
  • org_golang_x_tools is updated to master as of 2021-03-05.
  • org_golang_google_genproto is updated to master as of 2021-03-05.
  • go_googleapis is updated to master as of 2021-03-05.

WORKSPACE code

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
    name = "io_bazel_rules_go",
    sha256 = "7c10271940c6bce577d51a075ae77728964db285dac0a46614a7934dc34303e6",
    urls = [
        "https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.26.0/rules_go-v0.26.0.tar.gz",
        "https://github.com/bazelbuild/rules_go/releases/download/v0.26.0/rules_go-v0.26.0.tar.gz",
    ],
)

load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_dependencies")

go_rules_dependencies()

go_register_toolchains(version = "1.16")