1.0.1 • Published 2 years ago

windows-bin v1.0.1

Weekly downloads
4
License
MIT
Repository
github
Last release
2 years ago

windows-bin

Find Windows core executables like cscript, preferring the native 64-bit version regardless of Node.js bitness. Because by default, when running 32-bit Node.js, Windows would redirect to 32-bit WoW64 executables.

npm status AppVeyor build status Standard

Usage

const bin = require('windows-bin')

// C:\Windows\Sysnative\cscript.exe
bin('cscript', function(err, path) {
  console.log(path)
})

// C:\Windows\system32\cscript.exe
bin('cscript', { native: false }, function(err, path) {
  console.log(path)
})

Install

With npm do:

npm install windows-bin

License

MIT