enhanced-sketchtool

0.1.0 • Public • Published

enhanced-sketchtool

Install

$ npm i -D enhanced-sketchtool
$ yarn add -D enhanced-sketchtool

CLI Usage

$ npx sketchtool help
$ yarn sketchtool help

Node Usage

import {sketchtool, sketchtoolSync} from 'enhanced-sketchtool'
 
async function getSketchHelp () {
  const {stdout, status} = await sketchtool(['help']) // node style cb available too!
  if (status !== 0) {
    throw new Error('halp')
  }
  return stdout
}
 
// you want to print to this process' stdout
// (thus preventing useful return values)?
await sketchtool(['help'], {stdio: 'inherit'})
 
// you want sync?
sketchtoolSync(['help'], {/* ... spawnSync options */})

Contribution

PRs are most welcome!

Roadmap

  • get a better name
  • higher level option api
    • possibly parse help cmd to validate this?
  • in-memory sketch dumps / parsing

Readme

Keywords

none

Package Sidebar

Install

npm i enhanced-sketchtool

Weekly Downloads

4

Version

0.1.0

License

MIT

Unpacked Size

2.27 MB

Total Files

13

Last publish

Collaborators

  • jonjaques