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

chore: remove npm pre-commit package #2096

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

cprussin
Copy link
Collaborator

@cprussin cprussin commented Nov 5, 2024

This PR removes the npm pre-commit package which was added in https://github.com/pyth-network/pyth-crosschain/pull/805/files.

It appears that this package was added in a misguided attempt to get an automated installer for the pre-commit hook framework. However, the npm package, despite sharing the same name, actually has nothing to do with that framework. Instead, the npm package just created a git pre-commit hook that runs npm test at the repo root.

This was a no-op until I added turborepo, because prior to adding turborepo, there was no test script at the root. When I added turbo repo, I set up a test script at the root which runs turbo test -- effectively running tests across every package in the monorepo.

I believe this behavior is correct, but it's far too heavyweight to run as a pre-commit hook. Since it appears that the pre-commit npm package was added unintentionally and never did what it was expected to do, I think the right path forward is to remove the package for now so folks aren't experiencing slow pre-commit hooks. Later, I can figure out a better way to hook up useful bits of turborepo to the pre-commit framework, and I can also figure out an automated way to get the framework hooks installed.

@cprussin cprussin requested a review from ali-bahjati November 5, 2024 17:54
Copy link

vercel bot commented Nov 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
api-reference ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 5, 2024 6:11pm
component-library ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 5, 2024 6:11pm
insights ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 5, 2024 6:11pm
proposals ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 5, 2024 6:11pm
staking ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 5, 2024 6:11pm

Copy link

vercel bot commented Nov 5, 2024

@cprussin is attempting to deploy a commit to the Pyth Network Team on Vercel.

A member of the Team first needs to authorize it.

@cprussin cprussin merged commit c128715 into pyth-network:main Nov 5, 2024
8 checks passed
@cprussin cprussin deleted the remove-npm-pre-commit-package branch November 5, 2024 19:28
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