From 6f0e911dd1176bc2137f697cf6916f97b2291515 Mon Sep 17 00:00:00 2001 From: beorn7 Date: Thu, 7 Feb 2019 15:11:13 +0100 Subject: [PATCH 1/2] Fix the assets make target Presumable, it broke with the introduction of Go modules Signed-off-by: beorn7 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index e3ae23cf..34c34730 100644 --- a/Makefile +++ b/Makefile @@ -28,7 +28,7 @@ PRECHECK_OPTIONS_bzr = version build-all: assets apiv2 build assets: ui/app/script.js ui/app/index.html ui/app/lib template/default.tmpl - cd $(PREFIX)/asset && $(GO) generate + GO111MODULE=$(GO111MODULE) $(GO) generate ./asset @$(GOFMT) -w ./asset ui/app/script.js: $(shell find ui/app/src -iname *.elm) api/v2/openapi.yaml From f7e4d7b37535c32c0e52655d4dfb0d4dccedb393 Mon Sep 17 00:00:00 2001 From: beorn7 Date: Thu, 7 Feb 2019 15:43:23 +0100 Subject: [PATCH 2/2] Update scripts/errcheck_excludes.txt With Go modules, the path appears un-vendored. Plus, we are not calling AllowedLevel.Set anywhere anymore. Signed-off-by: beorn7 --- scripts/errcheck_excludes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/errcheck_excludes.txt b/scripts/errcheck_excludes.txt index caef015e..8fb66258 100644 --- a/scripts/errcheck_excludes.txt +++ b/scripts/errcheck_excludes.txt @@ -3,8 +3,8 @@ fmt.Fprintf fmt.Fprintln +// Exclude both vendored and un-vendored to cover both vendor mode and module mode. (github.com/prometheus/alertmanager/vendor/github.com/go-kit/kit/log.Logger).Log -// Allowed log levels are enforced via kingpin -(*github.com/prometheus/alertmanager/vendor/github.com/prometheus/common/promlog.AllowedLevel).Set +(github.com/go-kit/kit/log.Logger).Log // Generated via go-swagger (*github.com/prometheus/alertmanager/api/v2/restapi.Server).Shutdown