Am new to node js . I have installed nodejs in C:\Program Files\nodejs . and installed socket io. I tried to create some sample application in E:\harilal\node. i got error "cannot find socket io" . after searching installed socket.io in the app folder using npm. Now it's working fine. Is i need to install socket.io for every app separately. Is it possible to install it in node installation directory and use it in apps?
On Friday, October 5, 2012 10:09:38 AM UTC+2, harilal pillai wrote:
> hello,
> Am new to node js . I have installed nodejs in C:\Program Files\nodejs . > and installed socket io. I tried to create some sample application > in E:\harilal\node. i got error "cannot find socket io" . after searching > installed socket.io in the app folder using npm.
Now it's working fine. Is i need to install socket.iofor every app separately. Is it possible to install it in
> node installation directory and use it in apps?
> Regards > Harilal
This is a known issue. Try setting the HOME environment variable. On the command line enter set HOME=%USERPROFILE%
By the way, installing socket.io for every app is sort of the recommended way of doing things.
On Friday, October 5, 2012 7:51:35 AM UTC-4, Bert Belder wrote:
> On Friday, October 5, 2012 10:09:38 AM UTC+2, harilal pillai wrote:
>> hello,
>> Am new to node js . I have installed nodejs in C:\Program Files\nodejs . >> and installed socket io. I tried to create some sample application >> in E:\harilal\node. i got error "cannot find socket io" . after searching >> installed socket.io in the app folder using npm.
> Now it's working fine. Is i need to install socket.iofor every app separately. Is it possible to install it in >> node installation directory and use it in apps?
>> Regards >> Harilal
> This is a known issue. Try setting the HOME environment variable. On the > command line enter > set HOME=%USERPROFILE%
> By the way, installing socket.io for every app is sort of the recommended > way of doing things.
@BlondAngelNYC Actually am also a newbie. Just started to work with nodejs. I didn't understand the idea of running from commandline and from webserver. Could you please tell me more about it?
On Friday, October 5, 2012 8:11:15 PM UTC+5:30, BlondAngelNYC wrote:
> I am a newbie myself. I wanted to use ExpressJS for two projects. This > is what I have learned:
> If you are running things from the commandline, you can use 'npm install > -g <name>' to use the module.
> If you are running within a webserver, you need to install it locally with > 'npm install <name>'
> Once I understood the distinction, then everything makes sense.
> On Friday, October 5, 2012 7:51:35 AM UTC-4, Bert Belder wrote:
>> On Friday, October 5, 2012 10:09:38 AM UTC+2, harilal pillai wrote:
>>> hello,
>>> Am new to node js . I have installed nodejs in C:\Program Files\nodejs . >>> and installed socket io. I tried to create some sample application >>> in E:\harilal\node. i got error "cannot find socket io" . after searching >>> installed socket.io in the app folder using npm.
>> Now it's working fine. Is i need to install socket.iofor every app separately. Is it possible to install it in >>> node installation directory and use it in apps?
>>> Regards >>> Harilal
>> This is a known issue. Try setting the HOME environment variable. On the >> command line enter >> set HOME=%USERPROFILE%
>> By the way, installing socket.io for every app is sort of the >> recommended way of doing things.
I don't like installing anything globally since I work on multiple projects. I like each project to be self contained including the utilities it requires. For example, coffee. The workaround is to prepend
`node_modules/.bin` to PATH
This way local scripts are used if they exist. Declare command line utilities under `devDependencies` in package.json.
On Friday, October 5, 2012 7:41:15 AM UTC-7, BlondAngelNYC wrote:
> I am a newbie myself. I wanted to use ExpressJS for two projects. This > is what I have learned:
> If you are running things from the commandline, you can use 'npm install > -g <name>' to use the module.
> If you are running within a webserver, you need to install it locally with > 'npm install <name>'
> Once I understood the distinction, then everything makes sense.
> On Friday, October 5, 2012 7:51:35 AM UTC-4, Bert Belder wrote:
>> On Friday, October 5, 2012 10:09:38 AM UTC+2, harilal pillai wrote:
>>> hello,
>>> Am new to node js . I have installed nodejs in C:\Program Files\nodejs . >>> and installed socket io. I tried to create some sample application >>> in E:\harilal\node. i got error "cannot find socket io" . after searching >>> installed socket.io in the app folder using npm.
>> Now it's working fine. Is i need to install socket.iofor every app separately. Is it possible to install it in >>> node installation directory and use it in apps?
>>> Regards >>> Harilal
>> This is a known issue. Try setting the HOME environment variable. On the >> command line enter >> set HOME=%USERPROFILE%
>> By the way, installing socket.io for every app is sort of the >> recommended way of doing things.