UNPKG

await-exec-typescript

Version:

Small promise wrapper around node's `child_process#exec` allowing you to use async/await syntax for commands you want to execute.

10 lines (7 loc) 186 B
const exec = require("./index.js").default; async function logger(text) { await exec(`echo ${text}`, { log: true }); } for (let k = 0; k < 10; k++) { logger("worked!"); }