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

Add pre-commit hooks for linting & tests #155

Merged
merged 5 commits into from
May 2, 2022
Merged

Conversation

Headline
Copy link
Owner

@Headline Headline commented May 2, 2022

I was recently inspired by compiler explorer's pre-commit hooks. Using GitHub Actions to execute tests was consistently holding up my workflow, relying on builders to download our entire toolchain, check syntax, and run tests has been painful to say the least.

This new strategy involves bringing in a dev dependency to install git hooks, which will execute the following in order

  • cargo fmt
  • cargo clippy
  • cargo test

This will greatly improve the speed of the development cycle, and prevent having to wait on builders.

Furthermore, we're bringing clippy back as, since it's removal, lots of skeletons I am ashamed of appeared. This patch includes all of the changes to satisfy clippy.

@Headline Headline added build Edit to the build system, dependencies, or test suite dependencies Pull requests that update a dependency file labels May 2, 2022
@Headline Headline merged commit 34ea85d into master May 2, 2022
@Headline Headline deleted the pre-commit-hooks branch May 2, 2022 11:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Edit to the build system, dependencies, or test suite dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant