From 2ec026b05fe5a3cb84b5c7e6da1966bd7cc6b5ac Mon Sep 17 00:00:00 2001 From: Jacob Gadikian Date: Wed, 10 Aug 2022 23:49:07 +0700 Subject: [PATCH] chore: update make format (#12892) --- .golangci.yml | 9 +-------- CHANGELOG.md | 1 + Makefile | 5 ++--- 3 files changed, 4 insertions(+), 11 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 173d530b9..0fd62ef0a 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -12,8 +12,7 @@ linters: - exportloopref - goconst - gocritic - - gofmt - - goimports + - gofumpt - gosec - gosimple - govet @@ -32,12 +31,6 @@ issues: - text: "Use of weak random number generator" linters: - gosec - - text: "comment on exported var" - linters: - - golint - - text: "don't use an underscore in package name" - linters: - - golint - text: "ST1003:" linters: - stylecheck diff --git a/CHANGELOG.md b/CHANGELOG.md index 24fdc6e3a..38dcebbd6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* [#12892](https://github.com/cosmos/cosmos-sdk/pull/12892) `make format` now runs only gofumpt and golangci-lint run ./... --fix, replacing `goimports` `gofmt` and `misspell` * [#12846](https://github.com/cosmos/cosmos-sdk/pull/12846) Remove `RandomizedParams` from the `AppModuleSimulation` interface which is no longer needed. * (events) [#12850](https://github.com/cosmos/cosmos-sdk/pull/12850) Add a new `fee_payer` attribute to the `tx` event that is emitted from the `DeductFeeDecorator` AnteHandler decorator. * (ci) [#12854](https://github.com/cosmos/cosmos-sdk/pull/12854) Use ghcr.io to host the proto builder image. Update proto builder image to go 1.19 diff --git a/Makefile b/Makefile index 2c57fc741..254db5960 100644 --- a/Makefile +++ b/Makefile @@ -357,9 +357,8 @@ lint-fix: .PHONY: lint lint-fix format: - find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -path "./tests/mocks/*" -not -name '*.pb.go' | xargs gofmt -w -s - find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -path "./tests/mocks/*" -not -name '*.pb.go' | xargs misspell -w - find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -path "./tests/mocks/*" -not -name '*.pb.go' | xargs goimports -w -local github.com/cosmos/cosmos-sdk + find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" -not -path "./tests/mocks/*" -not -name "*.pb.go" -not -name "*.pb.gw.go" -not -name "*.pulsar.go" -not -path "./crypto/keys/secp256k1/*" | xargs gofumpt -w -l + golangci-lint run --fix .PHONY: format ###############################################################################