Tag: windows

nodejs applicaiton giving error “%1 is not a valid Win32 application” in windows machine

My Nodejs application works fine in ubuntu. When i tried to deploy the same in Windows machine it showed below error. =>node server.js D:\home\site\wwwroot D:\home\site\wwwroot\node_modules\ffi\node_modules\bindings\bindings.js:83 throw e ^ Error: %1 is not a valid Win32 application. D:\home\site\wwwroot\node_modules\ffi\node_modules\ref\build\Release\binding.node at Error (native) at Module.load (module.js:355:32) at Function.Module._load (module.js:310:12) at Module.require (module.js:365:17) at require (module.js:384:17) at bindings I […]

Windows Error : Source Path Too Long

Explanation : There are about 15 subfolders in the node_modules directory.When going to perform any operation(deleted, moved or renamed) it popup below message. Error message: The source file name(s) are larger than is supported by the file system. Try moving to a location which has a shorter path name, or try renaming to shorter name(s) […]

Installing gulp to windows 10

I’ve installed gulp npm install –global gulp and set envidoment variable: – variable: GULP_HOME – Value: C:\Users\myaccount\AppData\Roaming\npm\node_modules\gulp (..\gulp is folder) in environment variables And try to run “gulp”. Then i get a message in cmd: C:\myaccount\workspace\todoparrot>gulp [09:47:24] Local gulp not found in C:\myaccount\workspace\todoparrot How to set gulp to work?

How many child processes can a node.js cluster spawn on a 64bit Wintel PC?

I was running a concurrency test, and for brevity’s sake, defined a process for each spoofed http request. It worked fine for up to 64 requests/processes, but folded on 65. I’m running Window 7 (64bit) on an I5 laptop, with 4GB of Ram. Whilst running the test I had a Chrome open (with a handful […]

Running tsc from the Windows command line

npm is installed and is actively being used from IntelliJ IDEA 15 My goal is to generate typings for my TypeScript source code in IntelliJ, but I want to learn using the Windows command line, so I can explicitly specify the command line options to tinker to understand what each option does. I am confused […]

wrong encoding when using child_process spawn or exec under Windows

Using the dir command in Windows CMD will result in the following output: Verzeichnis von D:\workspace\filewalker 22.12.2013 17:27 <DIR> . 22.12.2013 17:27 <DIR> .. 22.12.2013 17:48 392 test.js 22.12.2013 17:23 0 testöäüÄÖÜ.txt 22.12.2013 17:27 <DIR> testÖÄÜöüäß 2 Datei(en), 392 Bytes 3 Verzeichnis(se), 273.731.170.304 Bytes frei Using exec or spawn will result in this: Verzeichnis von […]

Detect if executable exists on system path with node

Question Is there a simple way to tell if a system executable is available on the system path using node? For example if a user has python installed at /usr/bin/python and /usr/bin is in $PATH how can I detect that in Node? And conversely detect when something isn’t installed or is just not on path, […]

npm is very slow on Windows 10

This question is basically a duplicate of this one, except that the accepted answer on that question was, “it’s not actually slower, you just weren’t running the timing command correctly.” In my case, it actually is slower! 🙂 I’m on Windows 10. Here’s the output from PowerShell’s Measure-Command (the TotalMilliseconds line represents wall-clock time): PS> […]

electron and node on windows, kill a spawned process

i’m starting a background process (on windows) from electron main, something like this: app_exe = require(“child_process”).spawn( “app.exe” , [ “–params”, … ], { stdio: “ignore” } ); this works fine, i can see this from process explorer: but i cannot kill the process when the electron is closed ( .on(“closed”) or on(“window-all-closed”) ) i tried […]

Can Yarn and NVM Coexist on Windows?

Yarn was working for me until I decided I needed multiple versions of node. So I uninstalled yarn and installed nvm, following instructions from the following guide I then successfully re-installed yarn using the msi installer. Unfortunately, yarn global add [name] installed packages in a location seemingly spanning all nvm-controlled node versions, and yet equally […]

Node.js is the Best Javascript runtime in the world.