-
Notifications
You must be signed in to change notification settings - Fork 2.1k
don't run cargo fmt --all
in pre-commit hook
#3403
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
9 Ignored Deployments
|
🟢 CI successful 🟢Thanks |
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.
is it possible to only run cargo fmt
when relevant rust files change? this looks like it's not going to touch any of those files, so the pre-commit hook shouldn't apply. (I'm not sure if lint-staged is already supposed to be doing that?)
it actually does already: https://github.com/vercel/turbo/blob/a3bfa40ccd67862b3640731d06a2529a455fd2e5/package.json#L51 ...but @ForsakenHarmony was there a reason to format everything on every change? |
@wbinnssmith we can remove it |
a3bfa40
to
a4ea2d4
Compare
cargo fmt --all
in pre-commit hook
Why do we have the google font data in our repo though, I thought we wanted to use it from the next package directly ( |
Yeah, we do (WEB-415). We just haven't gotten to it yet, and this was breaking. |
This action started failing because
cargo fmt
was added to the pre-commit hook and the tool is not available without running Rust setup. Instead, we should just skip applying hooks when creating commits from this workflow.Since the create-pull-request doesn't have a way of disabling hooks, simply remove the file before husky installs it into place.Letcargo fmt
run on individual files through lint-staged, but don't run it on everything on every precommit.Test Plan: Manual workflow run on this branch which opened #3401