Last active
August 29, 2015 14:02
-
-
Save ddspringle/d1b8dde9ddb2fe4008b9 to your computer and use it in GitHub Desktop.
Getting local server username in Windows using Node.js
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
var exec = require('child_process').exec, | |
child; | |
child = exec('echo %username%', | |
function (error, stdout, stderr) { | |
console.log('username: ' + stdout); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment