@achievewithoutborders/node-exec

A simple node js exec wrapper

Usage no npm install needed!

<script type="module">
  import achievewithoutbordersNodeExec from 'https://cdn.skypack.dev/@achievewithoutborders/node-exec';
</script>

README

NodeJs Exec Wrapper

A simple node js exec wrapper

Syntax Async

args = { command, debug }
    command = string
    debug = boolean optional # will show console output

callback = (result,error)=> {}

Execute.async(args, callback)

Syntax Sync (Promise)

args = { command, debug }
    command = string
    debug = boolean optional # will show console output

Execute.sync(args)

Usage

const Execute = require('@achievewithoutborders/node-exec')

Execute.async({ 'ls', debug: true }, (result, error) =>
    console.log(result, error)
)

Execute.sync(args).then(res => console.log(res))