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

fix: speed up precommit hooks #1820

Merged
merged 1 commit into from May 7, 2021
Merged

fix: speed up precommit hooks #1820

merged 1 commit into from May 7, 2021

Conversation

karrui
Copy link
Contributor

@karrui karrui commented May 6, 2021

Problem

We have been installing a fresh version of lint-staged every precommit due to the script in husky/pre-commit. This caused every commit to take ~1 second at least and we pretty bad dev-exp.

This PR instead runs an npm script to use the installed lint-staged module, thus greatly(?) speeding up the pre-commit hook.

@karrui karrui requested a review from yong-jie May 6, 2021 18:53
@liangyuanruo
Copy link
Contributor

Good one! Explains why they took so long

@liangyuanruo liangyuanruo merged commit b9c43c0 into develop May 7, 2021
@liangyuanruo liangyuanruo deleted the fix/speed-precommit branch May 7, 2021 02:07
@karrui karrui mentioned this pull request May 11, 2021
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.

None yet

2 participants