Gentoo Archives: gentoo-dev

From: "Jesus Rivero (Neurogeek)" <neurogeek@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] NPM / NodeJS project
Date: Tue, 30 Jun 2015 17:04:20
Message-Id: CAD3zpDmnxGPLPTK3isoY2naTBQkhrZJ41CE1JqeGx6f+q7CWWQ@mail.gmail.com
In Reply to: Re: [gentoo-dev] NPM / NodeJS project by Michael Orlitzky
1 FWIW, I also bumped into this in my previous job.
2 I even wrote this (https://github.com/neurogeek/g-npm) which is incomplete
3 but saved me a bunch of time creating a crazy amount of npm ebuilds.
4
5 <kinda rant>
6 My experience is, this isn't worth it. npm is a mess, is
7 maintainer-unfriendly (although it might be argued that it is
8 developer-friendly) and they basically don't care about about distributions
9 at all.
10 npm packages are not meant to be installed globally. They are content with
11 having duplicate dependencies laying around everywhere.
12
13 Their "semantic versioning" sucks. They 1.4.1.2 can break backwards
14 compatibility with 1.4.1.1 and nobody cares.
15 I didn't find a way to download specific versions, and had trouble when
16 they did stuff like "depend on 1.4.x", because of the above.
17
18 Also, although minor point, the other reason I stopped pursuing this was
19 because I think npm packages are needlessly small. So, you might want to
20 install a package that depends on tens of other packages that depend on
21 tens of packages themselves. Most of this packages are 10 lines of code.
22 So, I ended up real fat with an dev-nodejs category with over a hundred
23 packages.
24 </kinda rant>
25
26 Having said all that, this was at least a couple of years ago. They might
27 have come to their senses by now.
28
29 Cheers,
30
31 On Tue, Jun 30, 2015 at 10:06 AM, Michael Orlitzky <mjo@g.o> wrote:
32
33 > On 06/30/2015 03:56 AM, Ian Delaney wrote:
34 > >
35 > > Is this what I prompted about a year or more ago, and drew no interest
36 > > in pursuing the npm path? I cited an eclass called npm.eclass in a
37 > > dev's overlay. The conclusion was that using npm to install anything
38 > > competed with portage at a level that made it a 'no go'. This came
39 > > from members of the portage 'team'. It is a very awkward topic.
40 > >
41 >
42 > No, but we may have wound up with a similar idea. I only became
43 > interested last week when somebody gave me a coffeescript program to
44 > deploy at work and there was no coffeescript.
45 >
46 > My eclass isn't using npm to do the actual install, since npm won't do a
47 > global install. I am using it as a lazy way to run the test suite ("npm
48 > test"), and I'm defaulting to npmjs.org as HOMEPAGE/SRC_URI because they
49 > have nice predictable URLs. But the src_install manually copies the
50 > javascript bits to a location where node can find them.
51 >
52 >
53 >
54
55
56 --
57 Jesus Rivero (Neurogeek)
58 Gentoo Developer