Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/npm.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ class Npm {
// take a long time to resolve, but that is why process.exit is called explicitly
// in the exit-handler.
this.unrefPromises.push(this.#logFile.load({
command,
path: this.logPath,
logsMax: this.config.get('logs-max'),
timing: this.config.get('timing'),
Expand Down
6 changes: 5 additions & 1 deletion lib/utils/log-file.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,11 @@ class LogFiles {
this.#endStream()
}

load ({ path, logsMax = Infinity, timing } = {}) {
load ({ command, path, logsMax = Infinity, timing } = {}) {
if (['completion'].includes(command)) {
return
}

// dir is user configurable and is required to exist so
// this can error if the dir is missing or not configured correctly
this.#path = path
Expand Down