-
-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Go 1.19 format #20758
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
Go 1.19 format #20758
Conversation
Signed-off-by: jolheiser <[email protected]>
Signed-off-by: jolheiser <[email protected]>
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.
Small hint: comparing with hiding space makes the diff clearer. 😁
https://github.com/go-gitea/gitea/pull/20758/files?diff=unified&w=1
Update: CI failure is related to swagger, waiting for upstream, added a blocked label
Co-authored-by: zeripath <[email protected]>
Signed-off-by: jolheiser <[email protected]>
go-swagger/go-swagger#2808 got merged & tagged (v0.30.0) |
* upstream/main: Go 1.19 format (go-gitea#20758) [skip ci] Updated translations via Crowdin
The images used by Gitea's drone pipeline were upgraded to Go 1.19.x It causes the lint fails because Go 1.19 uses new code format. This PR partially backport #20758 (including the emoji-data sync), partially fix the format manually.
As of Go 1.19, doc comments have been enhanced and
gofmt
now formats them to be clearer.Thankfully, for the most part it's backwards compatible. That is, I formatted using a local 1.19, then when re-running
make fmt
using 1.18 there were no further changes.Therefore, I think this PR should fix cases where contributors have 1.19 locally and thus
make fmt
would cause unwanted noise in their PR.The one place in our codebase that seemed to behave differently was in our CSV test where I replaced a literal tab with
\t
, which is treated the same within the test and worked with the formatter on both versions.