Skip to content

Commit

Permalink
build: update to Go 1.18.1 (#5267)
Browse files Browse the repository at this point in the history
  • Loading branch information
schroederc committed Apr 28, 2022
1 parent b04a9e9 commit 6e551c5
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 27 deletions.
14 changes: 0 additions & 14 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,6 @@ load("//:setup.bzl", "kythe_rule_repositories")

kythe_rule_repositories()

# TODO(schroederc): remove this. This needs to be loaded before loading the
# go_* rules. Normally, this is done by go_rules_dependencies in external.bzl,
# but because we want to overload some of those dependencies, we need the go_*
# rules before go_rules_dependencies. Likewise, we can't precisely control
# when loads occur within a Starlark file so we now need to load this
# manually...
load("@io_bazel_rules_go//go/private:repositories.bzl", "go_name_hack")

maybe(
go_name_hack,
name = "io_bazel_rules_go_name_hack",
is_rules_go = False,
)

# gazelle:repository_macro external.bzl%_go_dependencies
load("//:external.bzl", "kythe_dependencies")

Expand Down
12 changes: 6 additions & 6 deletions external.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ load("//kythe/rust/cargo:crates.bzl", "raze_fetch_remote_crates")

def _rule_dependencies():
go_rules_dependencies()
go_register_toolchains(version = "1.18beta2")
go_register_toolchains(version = "1.18.1")
gazelle_dependencies()
rules_java_dependencies()
rules_proto_dependencies()
Expand Down Expand Up @@ -1155,13 +1155,13 @@ def _go_dependencies():

http_archive(
name = "org_golang_x_tools",
# v0.1.8, latest as of 2021-12-15
# v0.1.9, latest as of 2022-03-14
urls = [
"https://mirror.bazel.build/github.com/golang/tools/archive/v0.1.8.zip",
"https://github.com/golang/tools/archive/v0.1.8.zip",
"https://mirror.bazel.build/github.com/golang/tools/archive/v0.1.9.zip",
"https://github.com/golang/tools/archive/v0.1.9.zip",
],
sha256 = "aec8a9ade0974bafc290bad1c53fa2b4d2b87ac8a90bf5340ded216ff81d1b2a",
strip_prefix = "tools-0.1.8",
sha256 = "1d338afb3cd8013cfb035da6831dea2210efb0386c17b9c99b5e84724e3d733a",
strip_prefix = "tools-0.1.9",
patches = [
"@io_kythe//third_party/go:add_export_license.patch",
# deletegopls removes the gopls subdirectory. It contains a nested
Expand Down
4 changes: 0 additions & 4 deletions kythe/go/indexer/testdata/basic/imports.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ import (
//- @"\"strconv\"" ref/imports
//- Strconv=vname("package", "golang.org", _, "strconv", "go")
"strconv"

//- @"\"net/http\"" ref/imports
//- _NetHTTP=vname("package", "golang.org", _, "net/http", "go")
_ "net/http"
)

//- @fmt ref Fmt
Expand Down
9 changes: 6 additions & 3 deletions setup.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,13 @@ def kythe_rule_repositories():
)

maybe(
github_archive,
repo_name = "bazelbuild/rules_go",
commit = "d0d326e4a5df51b5103dcd332c9e4df06d0bbbf2",
http_archive,
name = "io_bazel_rules_go",
sha256 = "f2dcd210c7095febe54b804bb1cd3a58fe8435a909db2ec04e31542631cf715c",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
],
)

maybe(
Expand Down

0 comments on commit 6e551c5

Please sign in to comment.