Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function createPipeline (entryId, depRows, cb) {
var entry = getRow(entryId)
var pipeline = splicer.obj([
'pack', [ pack({ raw: true }) ],
'wrap', []
])
var basename = outname(entry)
b.emit('split.pipeline', pipeline, entry, basename)
var writer = pipeline.pipe(createOutputStream(basename, entry))
// allow the output stream to assign a name asynchronously,
// eg. one based on the hash of the bundle contents
// the output stream is responsible for saving the file in the correct location
writer.on('name', function (name) {
basename = name
})
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: true,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: true,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: opts.dedupe,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: true,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: opts.dedupe,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: true,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());
pipeline.emit('package', pkg);
self.emit('package', pkg);
});
this._mdeps.on('transform', function (tr, file) {
pipeline.emit('transform', tr, file);
self.emit('transform', tr, file);
});
var dopts = {
index: !opts.fullPaths && !opts.exposeAll,
dedupe: true,
expose: this._expose
};
this._bpack = bpack(xtend(opts, { raw: true }));
var pipeline = splicer.obj([
'record', [ this._recorder() ],
'deps', [ this._mdeps ],
'json', [ this._json() ],
'unbom', [ this._unbom() ],
'unshebang', [ this._unshebang() ],
'syntax', [ this._syntax() ],
'sort', [ depsSort(dopts) ],
'dedupe', [ this._dedupe() ],
'label', [ this._label(opts) ],
'emit-deps', [ this._emitDeps() ],
'debug', [ this._debug(opts) ],
'pack', [ this._bpack ],
'wrap', []
]);
if (opts.exposeAll) {
var basedir = defined(opts.basedir, process.cwd());