Skip to content

Commit b1a2e60

Browse files
committed
fixup! fix: hide banner for exec and explore
1 parent 58fd1cb commit b1a2e60

1 file changed

Lines changed: 8 additions & 9 deletions

File tree

lib/npm.js

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -229,17 +229,16 @@ class Npm {
229229
// to keep those from being leaked. We still do a best effort replaceInfo.
230230
this.#title = ['npm'].concat(replaceInfo(this.config.parsedArgv.remain)).join(' ').trim()
231231
process.title = this.#title
232+
// The cooked argv is also logged separately for debugging purposes. It is
233+
// cleaned as a best effort by replacing known secrets like basic auth
234+
// password and strings that look like npm tokens. XXX: for this to be
235+
// safer the config should create a sanitized version of the argv as it
236+
// has the full context of what each option contains.
237+
this.#argvClean = replaceInfo(this.config.parsedArgv.cooked)
238+
log.verbose('title', this.title)
239+
log.verbose('argv', this.#argvClean.map(JSON.stringify).join(' '))
232240
})
233241

234-
// The cooked argv is also logged separately for debugging purposes. It is
235-
// cleaned as a best effort by replacing known secrets like basic auth
236-
// password and strings that look like npm tokens. XXX: for this to be
237-
// safer the config should create a sanitized version of the argv as it
238-
// has the full context of what each option contains.
239-
this.#argvClean = replaceInfo(this.config.parsedArgv.cooked)
240-
log.verbose('title', this.title)
241-
log.verbose('argv', this.#argvClean.map(JSON.stringify).join(' '))
242-
243242
// logFile.load returns a promise that resolves when old logs are done being cleaned.
244243
// We save this promise to an array so that we can await it in tests to ensure more
245244
// deterministic logging behavior. The process will also hang open if this were to

0 commit comments

Comments
 (0)