Isolate tools dependencies in tools package (#293)

Use `./tools` to prevent callers of `go-winio` from needing to add tools
to their dependencies.

Similar to https://github.com/microsoft/hcsshim/pull/1840

Signed-off-by: Hamza El-Saawy <hamzaelsaawy@microsoft.com>
This commit is contained in:
Hamza El-Saawy
2023-07-21 15:31:44 -04:00
committed by GitHub
parent 4f41be6f64
commit 10d5703c7b
4 changed files with 35 additions and 15 deletions
+13
View File
@@ -0,0 +1,13 @@
//go:build tools
// This package contains imports to various tools used (eg, via `//go:generate`) within this repo.
//
// Calls to `go run <cmd/import/path>` (or `//go:generate go run <cmd/import/path>`) for go executables
// included here will use the version specified in `go.mod` and build the executable from vendored code.
//
// Based on golang [guidance].
//
// [guidance]: https://github.com/golang/go/wiki/Modules#how-can-i-track-tool-dependencies-for-a-module
package tools
import _ "golang.org/x/tools/cmd/stringer"