Skip to content

Commit b8f8b41

Browse files
committed
deps: @npmcli/[email protected]
1 parent 79f79c7 commit b8f8b41

File tree

31 files changed

+38
-484
lines changed

31 files changed

+38
-484
lines changed

DEPENDENCIES.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,7 @@ graph LR;
228228
npmcli-run-script-->npmcli-node-gyp["@npmcli/node-gyp"];
229229
npmcli-run-script-->npmcli-package-json["@npmcli/package-json"];
230230
npmcli-run-script-->npmcli-promise-spawn["@npmcli/promise-spawn"];
231+
npmcli-run-script-->proc-log;
231232
npmcli-smoke-tests-->npmcli-eslint-config["@npmcli/eslint-config"];
232233
npmcli-smoke-tests-->npmcli-mock-registry["@npmcli/mock-registry"];
233234
npmcli-smoke-tests-->npmcli-promise-spawn["@npmcli/promise-spawn"];
@@ -700,6 +701,7 @@ graph LR;
700701
npmcli-run-script-->npmcli-node-gyp["@npmcli/node-gyp"];
701702
npmcli-run-script-->npmcli-package-json["@npmcli/package-json"];
702703
npmcli-run-script-->npmcli-promise-spawn["@npmcli/promise-spawn"];
704+
npmcli-run-script-->proc-log;
703705
npmcli-run-script-->which;
704706
npmcli-smoke-tests-->npmcli-eslint-config["@npmcli/eslint-config"];
705707
npmcli-smoke-tests-->npmcli-mock-registry["@npmcli/mock-registry"];

lib/commands/ci.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ class CI extends ArboristWorkspaceCmd {
109109
args: [],
110110
scriptShell,
111111
stdio: 'inherit',
112-
banner: !this.npm.silent,
113112
event,
114113
})
115114
}

lib/commands/explore.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ class Explore extends BaseCommand {
5656
return runScript({
5757
...this.npm.flatOptions,
5858
pkg,
59-
banner: false,
6059
path,
6160
event: '_explore',
6261
stdio: 'inherit',

lib/commands/install.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,6 @@ class Install extends ArboristWorkspaceCmd {
168168
args: [],
169169
scriptShell,
170170
stdio: 'inherit',
171-
banner: !this.npm.silent,
172171
event,
173172
})
174173
}

lib/commands/publish.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,6 @@ class Publish extends BaseCommand {
7272
path: spec.fetchSpec,
7373
stdio: 'inherit',
7474
pkg: manifest,
75-
banner: !silent,
7675
})
7776
}
7877

@@ -131,15 +130,13 @@ class Publish extends BaseCommand {
131130
path: spec.fetchSpec,
132131
stdio: 'inherit',
133132
pkg: manifest,
134-
banner: !silent,
135133
})
136134

137135
await runScript({
138136
event: 'postpublish',
139137
path: spec.fetchSpec,
140138
stdio: 'inherit',
141139
pkg: manifest,
142-
banner: !silent,
143140
})
144141
}
145142

lib/commands/run-script.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ class RunScript extends BaseCommand {
114114
scriptShell,
115115
stdio: 'inherit',
116116
pkg,
117-
banner: !this.npm.silent,
118117
event: ev,
119118
args: evArgs,
120119
})

node_modules/.gitignore

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -181,11 +181,6 @@
181181
!/npm-user-validate
182182
!/p-map
183183
!/pacote
184-
!/pacote/node_modules/
185-
/pacote/node_modules/*
186-
!/pacote/node_modules/@npmcli/
187-
/pacote/node_modules/@npmcli/*
188-
!/pacote/node_modules/@npmcli/run-script
189184
!/parse-conflict-json
190185
!/path-key
191186
!/path-scurry

node_modules/@npmcli/run-script/lib/run-script-pkg.js

Lines changed: 14 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,6 @@ const { isNodeGypPackage, defaultGypInstallScript } = require('@npmcli/node-gyp'
55
const signalManager = require('./signal-manager.js')
66
const isServerPackage = require('./is-server-package.js')
77

8-
// you wouldn't like me when I'm angry...
9-
const bruce = (id, event, cmd, args) => {
10-
let banner = id
11-
? `\n> ${id} ${event}\n`
12-
: `\n> ${event}\n`
13-
banner += `> ${cmd.trim().replace(/\n/g, '\n> ')}`
14-
if (args.length) {
15-
banner += ` ${args.join(' ')}`
16-
}
17-
banner += '\n'
18-
return banner
19-
}
20-
218
const runScriptPkg = async options => {
229
const {
2310
event,
@@ -29,8 +16,6 @@ const runScriptPkg = async options => {
2916
pkg,
3017
args = [],
3118
stdioString,
32-
// note: only used when stdio:inherit
33-
banner = true,
3419
// how long to wait for a process.kill signal
3520
// only exposed here so that we can make the test go a bit faster.
3621
signalTimeout = 500,
@@ -59,9 +44,20 @@ const runScriptPkg = async options => {
5944
return { code: 0, signal: null }
6045
}
6146

62-
if (stdio === 'inherit' && banner !== false) {
63-
// we're dumping to the parent's stdout, so print the banner
64-
console.log(bruce(pkg._id, event, cmd, args))
47+
if (stdio === 'inherit') {
48+
let banner
49+
if (pkg._id) {
50+
banner = `\n> ${pkg._id} ${event}\n`
51+
} else {
52+
banner = `\n> ${event}\n`
53+
}
54+
banner += `> ${cmd.trim().replace(/\n/g, '\n> ')}`
55+
if (args.length) {
56+
banner += ` ${args.join(' ')}`
57+
}
58+
banner += '\n'
59+
const { output } = require('proc-log')
60+
output.standard(banner)
6561
}
6662

6763
const [spawnShell, spawnArgs, spawnOpts] = makeSpawnArgs({

node_modules/@npmcli/run-script/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@npmcli/run-script",
3-
"version": "7.0.4",
3+
"version": "8.0.0",
44
"description": "Run a lifecycle script for a package (descendant of npm-lifecycle)",
55
"author": "GitHub Inc.",
66
"license": "ISC",
@@ -25,6 +25,7 @@
2525
"@npmcli/package-json": "^5.0.0",
2626
"@npmcli/promise-spawn": "^7.0.0",
2727
"node-gyp": "^10.0.0",
28+
"proc-log": "^4.0.0",
2829
"which": "^4.0.0"
2930
},
3031
"files": [

node_modules/pacote/node_modules/@npmcli/run-script/LICENSE

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)