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

feat: custom json linter #91

Merged
merged 4 commits into from
Jan 15, 2025
Merged

feat: custom json linter #91

merged 4 commits into from
Jan 15, 2025

Conversation

twinguy
Copy link
Contributor

@twinguy twinguy commented Jan 15, 2025

This PR addresses: #80

  • Added new make targets (build-iota-linter, run-iota-linter and clean-iota-linter)
  • Updated .golangci.yml with linter specific configs
  • Updated CI pipeline to run custom linter
  • Added docs for linter usage

Failed Github Action run (Showing linter findings)
Successful Github Action run (Excluded modules folder in .golangci.yml)

Signed-off-by: twinguy <twinguy17@gmail.com>
Signed-off-by: twinguy <twinguy17@gmail.com>
Signed-off-by: twinguy <twinguy17@gmail.com>
Signed-off-by: twinguy <twinguy17@gmail.com>
@twinguy
Copy link
Contributor Author

twinguy commented Jan 15, 2025

@diyor28 Couple of notes on this PR. I initially attempted to package and deliver this as a golangci custom plugin but kept struggling with use their plugin architecture. I finally settled on simply building and running the linter using make targets which feels more straightforward. As always, feedback welcome.

@diyor28
Copy link
Contributor

diyor28 commented Jan 15, 2025

That's fine, as long as we add an issue to the backlog to later come back to this and make a golangci-lint plugin

@diyor28
Copy link
Contributor

diyor28 commented Jan 15, 2025

Is this supposed to be the line number after the semi column?
image

@twinguy
Copy link
Contributor Author

twinguy commented Jan 15, 2025

Yes, line number is provided by the code analyzer framework unless the entire JSON structure is invalid which it then hard codes to a value of 1.

@diyor28 diyor28 merged commit fb19856 into iota-uz:main Jan 15, 2025
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