I've got a similar situation to the one described in this question. Basically, I'm developing 2 node modules, say A and B, where A depends on B.
For local dev I clone both projects and leverage npm link by linking B globally then npm link B into A's local node_modules. Now any changes to B are automatically used by A. Great.
However, the problem is that sometimes devs forget to npm link when doing local development, and end up installing the latest official release of B. Quite often, that just happens to work since B doesn't always change significantly, but sometimes it fails in subtle ways and we get invalid bug reports and confused developers.
How should I structure my package.json for A, such that devs are forced to used the latest B if they clone A?
One idea is to bump the version number of B after doing a release, and then require that, which cannot be installed from npm. While that could work, it means you have to come up with arbitrary version numbers for unreleased work on master, and still doesn't prevent devs from forgetting to update both projects to latest, etc.
What are the strategies / conventions here that others are using to help with this kind of setup? Do you set dependencies to git urls? Do you use npm hooks?