mvdan / gofumpt

A stricter gofmt
https://pkg.go.dev/mvdan.cc/gofumpt
BSD 3-Clause "New" or "Revised" License
3.15k stars 110 forks source link

how to ignore certain folders? #304

Open cwrau opened 2 months ago

cwrau commented 2 months ago

In gitlab CI we'd like to cache the go packages, via GOPATH=$CI_PROJECT_DIR/.go, but this tool then fails to run , as it tries to format .go/pkg/mod/github.com/onsi/ginkgo/v2@v2.14.0/integration/_fixtures/reporting_fixture/malformed_sub_package/malformed_sub_package_suite_test.go:15:1: expected declaration, found NO_COMPILE

Is there a way to ignore a folder? Or maybe generally GOPATH? Or stuff inside hidden directories?