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: add better linting targets and CI #215

Merged
merged 1 commit into from
Oct 17, 2024

Conversation

tylerslaton
Copy link
Contributor

@tylerslaton tylerslaton commented Oct 16, 2024

This PR adds in a couple of new make targets:

  • make lint-api - Lints the API
  • make lint-admin - Lints the admin UI
  • make lint - The previous two combined

Along with this I've split out the CI to run the api lint on Go changes and admin lint on changes to the admin UI. This helps linting locally and saves some time on PRs so everything is not linted together.

@tylerslaton tylerslaton marked this pull request as draft October 17, 2024 13:06
@tylerslaton tylerslaton force-pushed the linter branch 3 times, most recently from 5fef25e to d9dc69d Compare October 17, 2024 16:18
@tylerslaton
Copy link
Contributor Author

tylerslaton commented Oct 17, 2024

Added in a temp commit to simulate what CI runs for each of these would look like.

Screenshot 2024-10-17 at 12 18 39 PM

Makefile Outdated
Comment on lines 30 to 31
go fmt ./... && \
go vet ./...
Copy link
Contributor

Choose a reason for hiding this comment

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

This should probably be the golangci-lint that we have used in other places.

@ryanhopperlowe
Copy link
Contributor

UI side looks good!

@tylerslaton
Copy link
Contributor Author

I removed the API linting for now since we want to use golangci lint instead. When we do that it'll be a larger undertaking.

@tylerslaton tylerslaton requested a review from thedadams October 17, 2024 18:40
@tylerslaton tylerslaton merged commit 4fee5b1 into obot-platform:main Oct 17, 2024
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.

3 participants