Created
September 17, 2016 01:06
-
-
Save anaisbetts/41a7cfbd2c2fc198bf32801663139dc0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
is64BitOperatingSystem: () => { | |
if (process.arch === 'x64') return true; | |
let sysRoot = 'C:\\Windows'; | |
if (fs.statSyncNoException(process.env.SYSTEMROOT || 'C:\\__nothere__')) { | |
sysRoot = process.env.SYSTEMROOT; | |
} | |
// If %SystemRoot%\SysNative exists, we are in a WOW64 FS Redirected application. | |
return !!fs.statSyncNoException(path.join(sysRoot, 'sysnative')); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment