Created
March 21, 2016 00:18
-
-
Save orkaa/717138e2fb68b47d4b52 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
#!/usr/bin/env coffee | |
exec = require('child_process').exec | |
getConfig = (cmd) -> | |
child = exec(cmd, (error, stdout, stderr) -> | |
if stderr or error | |
console.log 'stderr: ' + stderr | |
console.log 'error: ' + error | |
result = stdout.toString() | |
return result | |
) | |
krneki = getConfig 'ls -al' | |
console.log krneki |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment