From e690f65d94c9141e7e1e5307fdbf0649609b0c93 Mon Sep 17 00:00:00 2001 From: Daniel Canter Date: Thu, 3 Feb 2022 12:37:05 -0800 Subject: [PATCH] Bump go version to 1.17 in go.mod/CI 1.13 is sufficiently old at this point and net.ErrClosed from 1.16 will be nice to use. This change additionally runs go fmt to bring in the new 1.17 build tag syntax and builds the binaries in our CI with 1.17+. Signed-off-by: Daniel Canter --- .github/workflows/ci.yml | 2 +- backup.go | 1 + backup_test.go | 1 + ea_test.go | 1 + file.go | 1 + fileinfo.go | 1 + go.mod | 2 +- hvsock.go | 1 + pipe.go | 1 + pipe_test.go | 1 + privilege.go | 1 + privileges_test.go | 1 + sd.go | 1 + sd_test.go | 1 + 14 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4b24bde4..83e2f86c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,7 +17,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-go@v2 with: - go-version: '^1.15.0' + go-version: '^1.17.0' - run: go build ./pkg/etw/sample/ - run: go build ./tools/etw-provider-gen/ diff --git a/backup.go b/backup.go index 2be34af4..6b3f121f 100644 --- a/backup.go +++ b/backup.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/backup_test.go b/backup_test.go index 0522a127..eaa8a2e9 100644 --- a/backup_test.go +++ b/backup_test.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/ea_test.go b/ea_test.go index 1d2abd79..3e32076f 100644 --- a/ea_test.go +++ b/ea_test.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/file.go b/file.go index 0385e410..0d97e08d 100644 --- a/file.go +++ b/file.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/fileinfo.go b/fileinfo.go index 3ab6bff6..350c1096 100644 --- a/fileinfo.go +++ b/fileinfo.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/go.mod b/go.mod index f39a608d..a5bca01c 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/Microsoft/go-winio -go 1.13 +go 1.17 require ( github.com/sirupsen/logrus v1.7.0 diff --git a/hvsock.go b/hvsock.go index b632f8f8..dfc98059 100644 --- a/hvsock.go +++ b/hvsock.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/pipe.go b/pipe.go index 96700a73..58fa5f83 100644 --- a/pipe.go +++ b/pipe.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/pipe_test.go b/pipe_test.go index a4ddea59..aa0eb77c 100644 --- a/pipe_test.go +++ b/pipe_test.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/privilege.go b/privilege.go index c3dd7c21..120b6055 100644 --- a/privilege.go +++ b/privilege.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/privileges_test.go b/privileges_test.go index 36fe72f4..0d2f492b 100644 --- a/privileges_test.go +++ b/privileges_test.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/sd.go b/sd.go index db1b370a..ba7f7cfd 100644 --- a/sd.go +++ b/sd.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio diff --git a/sd_test.go b/sd_test.go index 0621def3..cb1291bc 100644 --- a/sd_test.go +++ b/sd_test.go @@ -1,3 +1,4 @@ +//go:build windows // +build windows package winio