JSPM

  • Created
  • Published
  • Downloads 41
  • Score
    100M100P100Q53135F
  • License MIT

Create tar archive of files matching glob(s)

Package Exports

  • nectar

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (nectar) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

nectar

Create tar archive of files matching glob(s)

Build Status Code Quality Code Coverage NPM Version

Install

$ npm install --save nectar

Usage

const nectar = require('nectar');

nectar(['resources/**/*.js']);
// returns a readable stream for an archive containing all .js files inside 'resources'

nectar(['resources/**/*.js'], 'bundle.tar');
// returns a promise for packing all .js files inside 'resources' into 'bundle.tar'

API

nectar(input, [output])

Creates a tar archive containing all files matched by the given input glob(s). The directory structure is preserved.

Returns a readable if no output argument is provided, or a promise for writing the tar archive to the given output destination.

input

Type: string|string[]

Input glob(s).

output

Type: string

Optional output path.

License

MIT © JM Versteeg

dependency Status devDependency Status