This question already has an answer here:
What is the equivalent of this in Golang. Basically I want to be able to execute a command get it in pieces as it comes out. This is a example of what I have in Node.js at the current moment.
var exec = require('child_process').exec;
exec('ls').stdout.on('data', data => {
console.log(data);
});
Intention: The intention is to run a command then use websockets to ouput it live so a server.
</div>