declextract
Extract top-level Go declarations from a file.
Installation
go install github.com/bastjan/declextract@latest
Usage
$ declextract my/go/file.go InterestingVar
Extract top-level Go declarations from a file.
go install github.com/bastjan/declextract@latest
$ declextract my/go/file.go InterestingVar