PrimeDAO / prime-launch-dapp

https://launch.prime.xyz
6 stars 13 forks source link

Pre-commit safety measures #304

Open testing-life opened 2 years ago

testing-life commented 2 years ago

We need to find a way to prevent faulty/unformatted code from finding its way into the repo. Proposed solutions are a combination of git hooks (Husky) and linter. One potential idea is to run npm run lint and npm run build on pre-commit hook and return 0 on any failures, Other options may be possible.

dkent600 commented 2 years ago

also npm run test

dkent600 commented 2 years ago

We should not add another linter. Should rely on what we've already got.

wantedsystem commented 2 years ago

@dkent600 i've created this branch https://github.com/PrimeDAO/prime-launch-dapp/tree/feature/precommit , i've added commitlint (https://github.com/conventional-changelog/commitlint) with husky to check if your commit messages meet the conventional commit format, and also lint-staged to do lint and prettier on the staged files We can also add npm run test on every commit

dkent600 commented 2 years ago

@wantedsystem Thanks but I'm putting it back in On Hold. We won't work on this until we're done with the Prime Launch release.