-
Notifications
You must be signed in to change notification settings - Fork 14
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
chore: fix Makefile for format and execute make format #230
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #230 +/- ##
=======================================
Coverage 44.94% 44.94%
=======================================
Files 8 8
Lines 1068 1068
=======================================
Hits 480 480
Misses 570 570
Partials 18 18
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To use make format
, we need to install goimports
. So how about adding golang.org/x/tools
in go.mod as using ggo install golang.org/x/tools/cmd/goimports
?
I think it is not needed because goimports is not needed to build or install fnsa. |
Ok, I understand. Thank you. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had mistaken at #221. We can fix this bug by adding ""
to the next line.
Line 119 in 225b581
-X github.com/Finschia/finschia-sdk/version.BuildTags=$(build_tags_comma_sep) \ |
This is a rollback in this changes.
https://github.com/Finschia/finschia/pull/221/files#diff-76ed074a9305c04054cdebb9e9aad2d818052b07091de1f20cad0bbac34ffb52L118-R119
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you know the import path sorting rule?
It uses goimports, but I don't know in what order goimports sort imports, sorry. |
I think this sorting rule is difference with ours. So this may make conflict with others. How do you think about this? |
How about replacing -local means
And, executed example is loloicci@6f2afa6 |
28fbb81
to
cb1a11f
Compare
d481494
to
532767f
Compare
8617ed1
to
c06df15
Compare
I replaced the lint tool for import with goimports-reviser. This enables to unify import block format. |
108e166
to
5c963a4
Compare
5c963a4
to
305aa2c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could jobs in workflow be combined into one? And if you want to use cache for next time, it maybe need reverse the order of "install tools" and "actions/cache".
0e72753
to
683da10
Compare
683da10
to
fae5fa3
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description
This PR fixes
make format
command and executes it.This PR replaces the lint tool for importing orders with goimports-reviser (https://github.com/incu6us/goimports-reviser). This makes it unify how to order imports regardless of how programmers separate imports into some blocks.
Motivation and context
Without this PR,
make format
formats client/docs/statik/statik.go and it causes a CI error.Without this PR, how to separate format blocks is on how programmers write them.
How has this been tested?
Not needed.
Checklist:
CHANGELOG.md