This article shows you how to analyze your applications that are written in Go. It assumes that you have already installed and authenticated with ShiftLeft.
Inspect analyzes only source code written in Go 1.12 (or later), not compiled applications.
To analyze your Go application, run:
sl analyze --app <name> [--cpg|--no-cpg] --go [<path>]
The name of the application to be analyzed
The flag identifying the application's language
Whether you want to analyze your application using the Code Property Graph (CPG) mode. With CPG mode, ShiftLeft builds the CPG locally, then uploads the CPG (instead of your application) to the cloud for analysis
The Go package to be analyzed (this is the same argument you'd pass to the Go's