PruvoNet / node-upgrade-checker

node cli tool to check if your dependencies are compatible with a desired node package
GNU General Public License v2.0
3 stars 0 forks source link

bug: need to add proper handling for monorepos #54

Open regevbr opened 4 years ago

regevbr commented 4 years ago

Currently, we are assuming the package files are located at the git repo listed in package.json, but in mono repos (like jest) that is not the case. Need to add logic to realize that is the case and handle it properly. initial solution that comes to mind is to check the name in the root packge.json file and if it does not match, iterate the folders for the proper directory In case that the repo is handled by lerna (lerna.json exists) It seems that the ci configs are still at the root directory so maybe this issue is not relevant at all...

regevbr commented 4 years ago

Actually, it seems that you one can specify the directory in the repo when using monorepos. I have already added that metadata to the package info DTO. I noticed that not all packages actually define it. I think that the issue here is not the ci configs, which will (I think) will always reside at the root directory, but that maybe the test scripts might be per package and I believe we should handle it in those cases.

Another thing is that monorepos that use yarn2 have a configuration in package.json to denote the sub packages, so we need to handle those as well