Neverending Pile of Messages
    Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    pump-promisepublic

    pump-promise

    Promise-enhancing wrapper for pump.

    npm install pump-promise

    Usage

    Simply pass the streams you want to pipe together to pump-promise as same as for the original pump.

    var pump = require('pump-promise')
    var fs = require('fs')
     
    var source = fs.createReadStream('/dev/random')
    var dest = fs.createWriteStream('/dev/null')
     
    pump(source, dest).then(function() {
      console.log('pipe finished', err)
    }).catch(function(err) {
      console.log('pipe error', err)
    });

    install

    npm i pump-promise

    Downloadsweekly downloads

    160

    version

    1.0.0

    license

    MIT

    repository

    github.com

    last publish

    collaborators

    • avatar