Skip to content

Commit

Permalink
(feat) Added configuration for pre-commit. Solved all issues found by…
Browse files Browse the repository at this point in the history
… pre-commit stepts, including golangci-lint
  • Loading branch information
abel committed Dec 21, 2023
1 parent 505179d commit 3736b38
Show file tree
Hide file tree
Showing 140 changed files with 698 additions and 592 deletions.
19 changes: 19 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
exclude: |
(?x)^(
proto/.*|
exchange/.*
)$
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: end-of-file-fixer
- id: check-yaml
- repo: https://github.com/dnephin/pre-commit-golang
rev: v0.5.0
hooks:
- id: go-fmt
- id: go-imports
- id: golangci-lint
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,4 +200,4 @@ Copyright © 2020 - 2022 Injective Labs Inc. (https://injectivelabs.org/)
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
limitations under the License.
2 changes: 1 addition & 1 deletion NOTICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ Copyright © 2020 - 2022 Injective Labs Inc. (https://injectivelabs.org/)
Originally released by Injective Labs Inc. under: <br />
Apache License <br />
Version 2.0, January 2004 <br />
http://www.apache.org/licenses/
http://www.apache.org/licenses/
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,4 @@ Copyright © 2020 - 2022 Injective Labs Inc. (https://injectivelabs.org/)
Originally released by Injective Labs Inc. under: <br />
Apache License <br />
Version 2.0, January 2004 <br />
http://www.apache.org/licenses/
http://www.apache.org/licenses/
7 changes: 4 additions & 3 deletions chain/auction/types/auction.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions chain/auction/types/genesis.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/auction/types/query.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/auction/types/tx.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions chain/crypto/ethsecp256k1/keys.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions chain/exchange/types/authz.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/events.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/exchange.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/genesis.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/proposal.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/query.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/exchange/types/tx.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions chain/exchange/types/wasm_maker_contract.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package types

import (
sdk "github.com/cosmos/cosmos-sdk/types"
"cosmossdk.io/math"
)

type MintToUser struct {
Expand All @@ -13,7 +13,7 @@ type MintToUserMsg struct {
MintToUser MintToUser `json:"mint_to_user"`
}

func NewMintToUserMsg(subaccountIDSender string, amount sdk.Int) MintToUserMsg {
func NewMintToUserMsg(subaccountIDSender string, amount math.Int) MintToUserMsg {
return MintToUserMsg{
MintToUser: MintToUser{
SubaccountIDSender: subaccountIDSender,
Expand Down
5 changes: 3 additions & 2 deletions chain/insurance/types/genesis.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions chain/insurance/types/insurance.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/insurance/types/query.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/insurance/types/tx.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions chain/ocr/types/genesis.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions chain/ocr/types/ocr.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 3736b38

Please sign in to comment.