-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
all: gofmt -s #7900
all: gofmt -s #7900
Conversation
This "simplify" flag mainly removes redundant types in expressions. Not particularly important, but a nice change that also makes gopls not show warnings.
Thank you for submitting this PR!
Getting other community members to do a review would be great help too on complex PRs (you can ask in the chats/forums). If you are unsure about something, just leave us a comment.
We currently aim to provide initial feedback/triaging within two business days. Please keep an eye on any labelling actions, as these will indicate priorities and status of your contribution. |
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.
is there a way to have this happen in the CI lint check as well, so it stays this way?
https://github.com/ipfs/go-ipfs/blob/master/.circleci/config.yml#L362
https://github.com/ipfs/go-ipfs/blob/master/mk/golang.mk#L67-L74
https://github.com/ipfs/go-ipfs/blob/master/bin/test-go-fmt#L7
Yep, from what you shared it seems like we could just add |
Yeah, i think adding -s to the gofmt line makes sense. i also haven't looked into the golanglint-ci config to see if there's a way to specify that for it's use of gofmt in it's lint checks. |
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.
One nit but otherwise ❤️.
|
(I believe I've applied the required fixes) |
Beware that Go tools including gofmt don't understand GNU flags, so you probably want |
😡 |
This "simplify" flag mainly removes redundant types in expressions.
Not particularly important, but a nice change that also makes gopls not
show warnings.