sudo-suhas / lint-staged-multi-pkg

Example repo to demonstrate use of `lint-staged` with multi-pkg projects
MIT License
188 stars 19 forks source link

Not working without learna #46

Open flyingnobita opened 3 years ago

flyingnobita commented 3 years ago

I'm trying to follow the instructions and I'm not using lerna and to "Manually call precommit in each package".

I'm following the instructions in section "Manually call precommit in each package", where I have a .lintstagedrc.yml in each project's own folder. lint-staged and husky has been installed at the project root. I've got husky setup with npm-run-all and husky is working with the precommit hook.

However, my hook doesn't seem to get called when I stage my files.

I think I'm missing some more configuration. Can you please provide more details on your instructions for the section "Manually call precommit in each package"?

Thank you very much!

sudo-suhas commented 2 years ago

Don't have any additional instructions that I could share. If you could share a minimal repo that can be used to reproduce the issue, I can try to take a look.

flyingnobita commented 2 years ago

Can you clarify that for "Manually call precommit in each package", besides installing husky at project root, I assume lint-staged should also be installed? (as this wasn't explicitly said in this section). Are there other things that need to be installed or configured?

sudo-suhas commented 2 years ago

Yes, I think tools used in the pre-commit hook would also need to be installed in each package. I had written down the instructions a few years ago so I do not remember all the details clearly, sorry about that.

flyingnobita commented 2 years ago

I see, thanks anyways!