Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add make targets #189

Merged
merged 3 commits into from
Aug 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,21 @@ clean:

.PHONY: go-mod-cache clean

FIND_ARGS := -name '*.go' -type f -not -name '*.pb.go'

## format: Run gofmt and goimports.
format:
@echo Formatting...
@find . $(FIND_ARGS) | xargs gofmt -d -s
@find . $(FIND_ARGS) | xargs goimports -w -local github.com/tendermint/fundraising
jaybxyz marked this conversation as resolved.
Show resolved Hide resolved

## lint: Run Golang CI Lint.
lint:
@echo Running gocilint...
@golangci-lint run --out-format=tab --issues-exit-code=0


.PHONY: lint format
###############################################################################
### Tests & Simulation ###
###############################################################################
Expand Down Expand Up @@ -219,10 +234,10 @@ containerProtoFmt=cosmos-sdk-proto-fmt-$(containerProtoVer)
proto-all: proto-format proto-gen proto-swagger-gen

proto-gen:
starport generate proto-go
ignite generate proto-go

proto-swagger-gen:
starport generate openapi
ignite generate openapi

proto-format:
@echo "Formatting Protobuf files"
Expand Down
3 changes: 2 additions & 1 deletion app/sim_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,13 @@ import (
slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types"
stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"
"github.com/stretchr/testify/require"
fundraisingtypes "github.com/tendermint/fundraising/x/fundraising/types"
"github.com/tendermint/starport/starport/pkg/cosmoscmd"
abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/libs/log"
tmproto "github.com/tendermint/tendermint/proto/tendermint/types"
dbm "github.com/tendermint/tm-db"

fundraisingtypes "github.com/tendermint/fundraising/x/fundraising/types"
)

func init() {
Expand Down
1 change: 1 addition & 0 deletions testutil/simapp/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
banktypes "github.com/cosmos/cosmos-sdk/x/bank/types"
stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"

fundraisingtypes "github.com/tendermint/fundraising/x/fundraising/types"
)

Expand Down
1 change: 1 addition & 0 deletions x/fundraising/keeper/bid_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (

sdk "github.com/cosmos/cosmos-sdk/types"
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"

"github.com/tendermint/fundraising/x/fundraising/types"

_ "github.com/stretchr/testify/suite"
Expand Down
1 change: 1 addition & 0 deletions x/fundraising/keeper/invariants.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"fmt"

sdk "github.com/cosmos/cosmos-sdk/types"

"github.com/tendermint/fundraising/x/fundraising/types"
)

Expand Down
3 changes: 2 additions & 1 deletion x/fundraising/types/bid_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/stretchr/testify/require"

"github.com/tendermint/fundraising/x/fundraising/types"
"github.com/tendermint/tendermint/crypto"

"github.com/tendermint/fundraising/x/fundraising/types"
)

func TestConvertToSellingAmount(t *testing.T) {
Expand Down
3 changes: 2 additions & 1 deletion x/fundraising/types/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/stretchr/testify/require"

"github.com/tendermint/fundraising/x/fundraising/types"
"github.com/tendermint/tendermint/crypto"

"github.com/tendermint/fundraising/x/fundraising/types"
)

func TestMustParseRFC3339(t *testing.T) {
Expand Down