[Pkg-javascript-devel] hello, plus node packaging questions.
Jérémy Lal
kapouer at melix.org
Tue Jan 31 14:44:48 UTC 2012
On 31/01/2012 15:06, Andrew Baxter wrote:
> On 31/01/12 12:51, Jérémy Lal wrote:
>> On 31/01/2012 13:40, Andrew Baxter wrote:
>>> OK. If I get the energy, I'll look into how hard it would be to make npm detect installed debian packages.
>> Considering how npm works,
>> I really don't understand what advantage that would bring.
>> Could you explain ?
>
> I was thinking that someone might want to install several nodejs based packages on their system.
> Say one has all its dependencies in debian, and they have all been installed that way, but the
> other hasn't been packaged for debian. Some of the second project's dependencies might be installed
> already on their system, but when they used npm to install it, these wouldn't be picked up and would
> have to be installed twice.
I assume we are talking about npm >= 1.0.
I agree that :
sudo aptitude install node-pg
npm link pg
Should give the same result as :
sudo npm -g install pg
npm link pg
But this always downloads a fresh copy to ./node_modules :
npm install pg
If you have a package.json listing 'pg' as one of its deps,
i don't think installing its package by :
npm install .
will link existing globally installed npm-packages.
If you really want to do that, as a pure npm user you'll have
to do :
sudo npm -g install pg
npm link pg
npm install .
Maybe a future version of npm will allow to skip the extra 'link before install'
step, but until then it does not seem necessary to do that task :
"fix 'npm link xxx' so that modules on node path (not installed by npm) are linked as well"
Jérémy.
>
> andy
>
> _______________________________________________
> Pkg-javascript-devel mailing list
> Pkg-javascript-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-javascript-devel
More information about the Pkg-javascript-devel
mailing list