Current Path: > > lib > node_modules > npm > node_modules > pacote
Operation : Linux premium131.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64 Software : Apache Server IP : 162.0.232.56 | Your IP: 216.73.216.111 Domains : 1034 Domain(s) Permission : [ 0755 ]
Name | Type | Size | Last Modified | Actions |
---|---|---|---|---|
lib | Directory | - | - | |
node_modules | Directory | - | - | |
CHANGELOG.md | File | 44436 bytes | March 10 2021 14:36:37. | |
LICENSE | File | 1103 bytes | March 10 2021 14:36:37. | |
README.md | File | 9833 bytes | March 10 2021 14:36:37. | |
extract.js | File | 3064 bytes | March 10 2021 14:36:37. | |
index.js | File | 262 bytes | March 10 2021 14:36:37. | |
manifest.js | File | 1147 bytes | March 10 2021 14:36:37. | |
package.json | File | 3430 bytes | March 10 2021 14:36:37. | |
packument.js | File | 822 bytes | March 10 2021 14:36:37. | |
prefetch.js | File | 1978 bytes | March 10 2021 14:36:37. | |
tarball.js | File | 2022 bytes | March 10 2021 14:36:37. |
'use strict' const BB = require('bluebird') const fs = require('fs') const getStream = require('get-stream') const mkdirp = BB.promisify(require('mkdirp')) const npa = require('npm-package-arg') const optCheck = require('./lib/util/opt-check.js') const PassThrough = require('stream').PassThrough const path = require('path') const rimraf = BB.promisify(require('rimraf')) const withTarballStream = require('./lib/with-tarball-stream.js') module.exports = tarball function tarball (spec, opts) { opts = optCheck(opts) spec = npa(spec, opts.where) return withTarballStream(spec, opts, stream => getStream.buffer(stream)) } module.exports.stream = tarballStream function tarballStream (spec, opts) { opts = optCheck(opts) spec = npa(spec, opts.where) const output = new PassThrough() let hasTouchedOutput = false let lastError = null withTarballStream(spec, opts, stream => { if (hasTouchedOutput && lastError) { throw lastError } else if (hasTouchedOutput) { throw new Error('abort, abort!') } else { return new BB((resolve, reject) => { stream.on('error', reject) output.on('error', reject) output.on('error', () => { hasTouchedOutput = true }) output.on('finish', resolve) stream.pipe(output) stream.once('data', () => { hasTouchedOutput = true }) }).catch(err => { lastError = err throw err }) } }) .catch(err => output.emit('error', err)) return output } module.exports.toFile = tarballToFile function tarballToFile (spec, dest, opts) { opts = optCheck(opts) spec = npa(spec, opts.where) return mkdirp(path.dirname(dest)) .then(() => withTarballStream(spec, opts, stream => { return rimraf(dest) .then(() => new BB((resolve, reject) => { const writer = fs.createWriteStream(dest) stream.on('error', reject) writer.on('error', reject) writer.on('close', resolve) stream.pipe(writer) })) })) }
SILENT KILLER Tool