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

Setup golines checker #116

Merged
merged 7 commits into from
Aug 26, 2024
Merged

Setup golines checker #116

merged 7 commits into from
Aug 26, 2024

Conversation

mkysel
Copy link
Collaborator

@mkysel mkysel commented Aug 26, 2024

Make sure that CI catches files that have not been formatted by golines.
Add a script that does the formatting and ignores autogenerated files.

Both idea and vscode will reformat a generated file if you save it. Since golines does not offer a good way to ignore these files correctly.

Here is the CI detecting a poorly formatted file: https://github.com/xmtp/xmtpd/actions/runs/10564716546/job/29267709565

@mkysel mkysel requested a review from richardhuaaa August 26, 2024 17:43
Copy link
Contributor

@richardhuaaa richardhuaaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for tackling this!

@@ -9,29 +9,29 @@ type ApiOptions struct {
}

type ContractsOptions struct {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could optionally exclude this file/directory too, up to you

@mkysel mkysel merged commit 4dc7b3d into main Aug 26, 2024
4 checks passed
@mkysel mkysel deleted the mkysel/golines branch August 26, 2024 18:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants