Lint executor
The lint executor formats and lints a Go project. By default it runs go fmt ./....
nx lint my-go-project
Options
Section titled “Options”| Option | Type | Default | Description |
|---|---|---|---|
linter | string | go fmt | The command to execute when running the lint executor instead of go fmt. |
args | string[] | - | Extra args when linting the project |
When linter is set, the executor runs that command with args and ./... appended, bypassing go fmt.
Inferred target
Section titled “Inferred target”Inferred for all Go projects (applications and libraries):
{
"executor": "@naxodev/gonx:lint",
"cache": true,
"inputs": [
"{projectRoot}/go.mod",
"{projectRoot}/go.sum",
"{projectRoot}/**/*.{go}"
]
}