Update yarn.lock whenever package.json changes
When you want to lock your deps, you may want to run yarn install
with --frozen-lockfile
.
This package is used to keep yarn.lock up-to-date and prevent the command above to fail.
The command should run on the pre-commit hook, it will update and stage the yarn.lock
file if package.json
is staged.
There's no need to install yarn-lock-fix, you can use it with npx.
Yarn-lock-fix is designed to work with npx and husky.
Use husky to the add the command to your pre-commit hook:
yarn husky add .husky/pre-commit "npx yarn-lock-fix"
Would like to help make this package better? Please take a look at the contributing guidelines for a detailed explanation on how you can contribute.
I'd like thank my daily coffee!