unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#23744: guix: npm don't run
@ 2016-06-10 13:31 Jovany Leandro G.C
  2016-06-12 20:30 ` Ludovic Courtès
  0 siblings, 1 reply; 3+ messages in thread
From: Jovany Leandro G.C @ 2016-06-10 13:31 UTC (permalink / raw)
  To: 23744

HI,
this distro it's amazing i very happy using it.

i install **guix package -i npm** version *6.0.0* node 
and when try **npm** this throws:

~~~
Error: Cannot find module '../lib/npm.js'
    at Function.Module._resolveFilename (module.js:438:15)
    at Function.Module._load (module.js:386:25)
    at Module.require (module.js:466:17)
    at require (internal/module.js:20:19)
    at /gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:26:13
    at Object.<anonymous>
(/gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:76:3)
at Module._compile (module.js:541:32) at Object.Module._extensions..js
(module.js:550:10) at Module.load (module.js:456:32)
    at tryModuleLoad (module.js:415:12)
~~~

i fix for working:

create a file $HOME/bin/npm
~~~
#!/bin/sh
node $HOME/.guix-profile/lib/node_modules/npm/bin/npm-cli.js $@
~~~

append to $HOME/.bashrc

~~~
export PATH=$HOME/bin:$PATH
~~~

and that's it, now npm works only for local install

for my case i run **npm install ionic@beta** and run **node
~/node_modules/ionic/bin/ionic**
and works :)

I hope to be helpful
thanks,

^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#23744: guix: npm don't run
  2016-06-10 13:31 bug#23744: guix: npm don't run Jovany Leandro G.C
@ 2016-06-12 20:30 ` Ludovic Courtès
  2016-06-29  8:08   ` Ludovic Courtès
  0 siblings, 1 reply; 3+ messages in thread
From: Ludovic Courtès @ 2016-06-12 20:30 UTC (permalink / raw)
  To: Jovany Leandro G.C; +Cc: Jelle Licht, 23744

Hello!

"Jovany Leandro G.C" <bit4bit@riseup.net> skribis:

> this distro it's amazing i very happy using it.

Thanks for your kind words.  :-)

> i install **guix package -i npm** version *6.0.0* node 
> and when try **npm** this throws:
>
> ~~~
> Error: Cannot find module '../lib/npm.js'
>     at Function.Module._resolveFilename (module.js:438:15)
>     at Function.Module._load (module.js:386:25)
>     at Module.require (module.js:466:17)
>     at require (internal/module.js:20:19)
>     at /gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:26:13
>     at Object.<anonymous>
> (/gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:76:3)
> at Module._compile (module.js:541:32) at Object.Module._extensions..js
> (module.js:550:10) at Module.load (module.js:456:32)
>     at tryModuleLoad (module.js:415:12)
> ~~~
>
> i fix for working:
>
> create a file $HOME/bin/npm
> ~~~
> #!/bin/sh
> node $HOME/.guix-profile/lib/node_modules/npm/bin/npm-cli.js $@
> ~~~

This seems to be related to:

  http://bugs.gnu.org/23723

Jelle: I gather you have a patch around that changes or removes the
‘patch-shebangs’ phase for npm?  Could you submit it on guix-devel?

TIA.  :-)

Ludo’.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#23744: guix: npm don't run
  2016-06-12 20:30 ` Ludovic Courtès
@ 2016-06-29  8:08   ` Ludovic Courtès
  0 siblings, 0 replies; 3+ messages in thread
From: Ludovic Courtès @ 2016-06-29  8:08 UTC (permalink / raw)
  To: Jovany Leandro G.C; +Cc: 23744-done, Jelle Licht

ludo@gnu.org (Ludovic Courtès) skribis:

> "Jovany Leandro G.C" <bit4bit@riseup.net> skribis:
>
>> this distro it's amazing i very happy using it.
>
> Thanks for your kind words.  :-)
>
>> i install **guix package -i npm** version *6.0.0* node 
>> and when try **npm** this throws:
>>
>> ~~~
>> Error: Cannot find module '../lib/npm.js'
>>     at Function.Module._resolveFilename (module.js:438:15)
>>     at Function.Module._load (module.js:386:25)
>>     at Module.require (module.js:466:17)
>>     at require (internal/module.js:20:19)
>>     at /gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:26:13
>>     at Object.<anonymous>
>> (/gnu/store/y98akn298a47sn3f7c19pzw98jw9a14b-node-6.0.0/bin/npm:76:3)
>> at Module._compile (module.js:541:32) at Object.Module._extensions..js
>> (module.js:550:10) at Module.load (module.js:456:32)
>>     at tryModuleLoad (module.js:415:12)
>> ~~~
>>
>> i fix for working:
>>
>> create a file $HOME/bin/npm
>> ~~~
>> #!/bin/sh
>> node $HOME/.guix-profile/lib/node_modules/npm/bin/npm-cli.js $@
>> ~~~
>
> This seems to be related to:
>
>   http://bugs.gnu.org/23723
>
> Jelle: I gather you have a patch around that changes or removes the
> ‘patch-shebangs’ phase for npm?  Could you submit it on guix-devel?

I pushed a workaround in Node itself as commit
2de091f0c8ee143b1dd07483b3b86a31870342c0.

Eventually we’ll push Jelle’s fix for #23723, but since that’s a
rebuild-the-world change, it’ll be some time before it’s available, so
this workaround is our best bet for now.

Thanks!

Ludo’.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-06-29  8:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-10 13:31 bug#23744: guix: npm don't run Jovany Leandro G.C
2016-06-12 20:30 ` Ludovic Courtès
2016-06-29  8:08   ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).