I have a project that I will have to deploy to Windows client systems, where it will be impossible to connect to the Internet. I currently have a folder in the D: \ NODE folder that contains node.exe and npm.cmd and the node_modules folder. To start node from the command line, I added D: \ NODE to the PATH variable.
I can use most of the modules installed locally inside the node_modules of my project. However, there is one - node-windows - that must be installed globally to work.
The following sentence below I went into node-windows (installed globally) and packaged it ( npm pack ), which created the tarball. Then I copied this file with my project and tried to install it on a test computer around the world as follows: npm install -g node-windows-0.1.5.tgz
I see that it has been installed in the global catalog. However, when I try to run a command that uses this module, it complains that it cannot find it: Error: Cannot find module 'node-windows'
When I list the modules ( npm list -g ), it is clearly present in the list ...
What do you think? And thanks.
Katya s
source share