A simple TypeScript/Node.js utility to spawn processes and get their output with async/await
 
Go to file
Kuba Orlik e5b5ea0621 Add README
src Initial commit
.gitignore Initial commit
.npmignore Rename
README.md Add README
package-lock.json Initial commit
package.json Rename
tsconfig.json Initial commit

README.md

An async wrapper for nodejs' spawn

import spawn from "async-spawner";
await simpleSpawn("ls", "-al");
import { deferedSpawn } from "async-spawner";
const ping = await deferedSpawn("ping", ["8.8.8.8"]);
let response;
do{
    response = await ping.waitForNextData();
    console.log("new ping!", response);
}
ping.kill();