munchhausen

2.0.2 • Public • Published

munchhausen

Automatically wrap operating system commands with duplex streams.

Named after Baron Munchausen who pulled him self out of a lake by his own hair. muenchhausen.jpg

Usage

import { pipeline } from 'stream';
import munchhausen from 'munchhausen';
const {cat, grep} = munchhausen;
pipeline(

  ...await Promise.all([
    cat("package.json"),
    grep(echo("name"))
  ]),

  err => console.error
).once('readable', function () {
  console.log( this.read().toString()) //  "name": "munchhausen",\n
})

Credit

Artwork Public Domain

/munchhausen/

    Package Sidebar

    Install

    npm i munchhausen

    Weekly Downloads

    3

    Version

    2.0.2

    License

    ISC

    Unpacked Size

    293 kB

    Total Files

    7

    Last publish

    Collaborators

    • catpea