The package is in a private repo, and I’m including it in the main project like this: "awesome-package": "git+ssh://git@ourserver:myuser/awesome-package.git"
Any ideas why the dependencies aren’t getting installed? Thanks in advance!
Have you considered the possibility that your postinstall script might be causing issues? The ‘nodemon setup’ command in your postinstall script could be interfering with the normal installation process. Try commenting out that script temporarily and see if it resolves the problem.
Another thing to check is your Git SSH URL. Ensure it’s correctly formatted and that you have the necessary permissions. Sometimes, subtle issues with the URL can prevent proper installation.
It’s also worth examining your .npmrc file, if you have one. Make sure it’s not overriding any crucial settings that could affect dependency installation from private repositories.
If none of these solve the issue, you might want to try clearing your npm cache (npm cache clean --force) and then reinstalling. This can sometimes resolve stubborn installation problems.
yo, have u tried removing the postinstall script? that nodemon setup might be messin things up. also, check ur git config and make sure ur ssh key is good. sometimes the problem is simpler than we think lol. if nothin else works, try npm ci instead of npm install. it’s stricter but can fix weird issues
I’ve encountered similar issues with private repo dependencies before. Here’s what worked for me:
Check if you’re using the latest version of npm. Older versions sometimes have trouble with Git dependencies.
Also, make sure your SSH key is properly set up and has access to the private repo. I once spent hours debugging only to realize my SSH key had expired.
If those don’t help, try running npm install with the --verbose flag. It’ll give you more detailed output about what’s happening during the install process.
Lastly, double-check that your postinstall script isn’t interfering. I’ve seen cases where complex postinstall scripts can cause dependency installation to fail silently.
Hope this helps! Let us know if you need more troubleshooting tips.