
Building the simplest Go static analysis tool
4/27/2016
This post details the creation of a simple Go static analysis tool, 'vendorcheck', designed to verify that all non-standard library dependencies are vendored. It explains how to use golang.org/x/tools/go/loader to load packages and their dependencies, how to identify standard library packages, and how to check for the presence of '/vendor/' in dependency paths. The post also provides a link to the tool's GitHub repository and recommends using golang.org/x/tools/go/loader over go/importer for static analysis.