Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

npm install without symlinks option not working

I setup a development environment with Windows 8 and Ubuntu as a virtual machine. For that I use VirtualBox.

I also manage to create a shared folder in VirtualBox.

In this shared folder I try to start a project with ember-generator of Yeoman.

yo ember --skip-install --karma npm install --no-bin-links 

For installing modules NPM I use the option "--no-bin-links" not to create symbolic links. Unfortunately, I still have errors creations symbolic links ... Is what I use although this option ? There he has a bug ?

like image 625
Bastien D Avatar asked Jan 29 '14 08:01

Bastien D


People also ask

How do I unlink a node module?

You can “undo” the effects of npm link by simply removing the symbolic links. But there is a built in command for it, aptly called: npm unlink . Just run npm unlink --no-save <module_name> on your project's directory to remove the local symlink, and run npm unlink on the module's directory to remove the global symlink.

What is no bin Link?

The --no-bin-links argument will prevent npm from creating symlinks for any binaries the package might contain.


1 Answers

The NPM docs about parameter "--no-bin-links" say:

will prevent npm from creating symlinks for any binaries the package might contain.

Which will just cause NPM to not create links in the node_modules/.bin folder. I also searched for a way to prevent NPM from creating symlinks when using npm install ../myPackage, but can't find any solution...

Update: The npm support team said this will reproduce the old behaviour (no symbolic links):

npm install $(npm pack <folder> | tail -1) 

Works for me in git-bash on Windows 10.

like image 102
TekTimmy Avatar answered Sep 20 '22 16:09

TekTimmy