diff options
Diffstat (limited to 'deps/npm/node_modules/tar/lib/pack.js')
-rw-r--r-- | deps/npm/node_modules/tar/lib/pack.js | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/deps/npm/node_modules/tar/lib/pack.js b/deps/npm/node_modules/tar/lib/pack.js index 09b6ac590b..8df366e118 100644 --- a/deps/npm/node_modules/tar/lib/pack.js +++ b/deps/npm/node_modules/tar/lib/pack.js @@ -88,6 +88,8 @@ const Pack = warner(class Pack extends MiniPass { this.portable = !!opt.portable this.noDirRecurse = !!opt.noDirRecurse this.follow = !!opt.follow + this.noMtime = !!opt.noMtime + this.mtime = opt.mtime || null this.filter = typeof opt.filter === 'function' ? opt.filter : _ => true @@ -291,17 +293,18 @@ const Pack = warner(class Pack extends MiniPass { strict: this.strict, portable: this.portable, linkCache: this.linkCache, - statCache: this.statCache + statCache: this.statCache, + noMtime: this.noMtime, + mtime: this.mtime } } [ENTRY] (job) { this[JOBS] += 1 try { - return new this[WRITEENTRYCLASS]( - job.path, this[ENTRYOPT](job)).on('end', _ => { - this[JOBDONE](job) - }).on('error', er => this.emit('error', er)) + return new this[WRITEENTRYCLASS](job.path, this[ENTRYOPT](job)) + .on('end', () => this[JOBDONE](job)) + .on('error', er => this.emit('error', er)) } catch (er) { this.emit('error', er) } @@ -378,7 +381,6 @@ class PackSync extends Pack { job.path.slice(this.prefix.length + 1) || './' : job.path - const base = p === './' ? '' : p.replace(/\/*$/, '/') this[ADDFSENTRY](base + entry) }) |