Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@wisniewski94
Forked from jtrefry/Win10-64bit-npm.md
Created May 21, 2019 12:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wisniewski94/fcbc3197657cc79de4b7b12164fef55a to your computer and use it in GitHub Desktop.
Save wisniewski94/fcbc3197657cc79de4b7b12164fef55a to your computer and use it in GitHub Desktop.
Configuring Windows 10 (64-bit) for npm and node-gyp
  • Install Git for Windows
  • Install Node
  • Install Python 2.7.3
  • Install Microsoft Visual Studio 2015 Community
  • Open the command prompt as Administrator, run the following commands, then close the command prompt (a new prompt is required before the new environment variables will be available)
    • npm install -g npm
      • (Upgrades to npm v3, which no longer nests dependencies indefinitely. No more "maximum path length exceeded" errors due to the 260 character path limit in Windows, or needing to delete node_modules with rimraf.)
    • setx PYTHON C:\Python27\python.exe /m
      • (May need to change path to your custom install directory.)
  • Open a new command prompt and run the following commands. If these install without errors, you have bypassed one of the most frustrating experiences for npm users on Windows.
    • npm install -g node-gyp
    • npm install -g socket.io
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment