diff options
| author | Shulhan <ms@kilabit.info> | 2025-02-03 21:36:10 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2025-02-03 21:40:14 +0700 |
| commit | a1635783753af6318ff192c1b41c16bb3f7fc76b (patch) | |
| tree | 02511e9615ac5c7a6c06958dc3f331ba07b7b413 /internal | |
| parent | 206fc899a4b90c85d3a0906eb4d13e9177082fbb (diff) | |
| download | gotp-a1635783753af6318ff192c1b41c16bb3f7fc76b.tar.xz | |
all: replace external linters with internal command
The fieldalignment and shadow linters are from golang.org/x/tools.
Those linters have an exposed APIs that can be combined into single
call or program, which provided by "pakakeh.go/lib/goanalysis".
This help reduce the tooling need to be installed or setup for
development.
Diffstat (limited to 'internal')
| -rw-r--r-- | internal/cmd/gocheck/main.go | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/internal/cmd/gocheck/main.go b/internal/cmd/gocheck/main.go new file mode 100644 index 0000000..cb9d378 --- /dev/null +++ b/internal/cmd/gocheck/main.go @@ -0,0 +1,17 @@ +// SPDX-FileCopyrightText: 2024 M. Shulhan <ms@kilabit.info> +// +// SPDX-License-Identifier: BSD-3-Clause + +// Program gocheck implement go static analysis using [Analyzer] that are not +// included in the default go vet. +// See package [lib/goanalysis] for more information. +// +// [Analyzer]: https://pkg.go.dev/golang.org/x/tools/go/analysis#hdr-Analyzer +// [lib/goanalysis]: https://pkg.go.dev/git.sr.ht/~shulhan/pakakeh.go/lib/goanalysis/ +package main + +import "git.sr.ht/~shulhan/pakakeh.go/lib/goanalysis" + +func main() { + goanalysis.Check() +} |
