@uides/stepwise 2.0.2 → 2.0.4-platform-162.23-01-26-13-03
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/generators/node_modules/@isaacs/cliui/build/lib/index.js +0 -211
- package/generators/node_modules/@pkgjs/parseargs/examples/is-default-value.js +0 -31
- package/generators/node_modules/@pkgjs/parseargs/examples/limit-long-syntax.js +0 -33
- package/generators/node_modules/@pkgjs/parseargs/examples/negate.js +0 -48
- package/generators/node_modules/@pkgjs/parseargs/examples/no-repeated-options.js +0 -38
- package/generators/node_modules/@pkgjs/parseargs/examples/simple-hard-coded.js +0 -36
- package/generators/node_modules/@pkgjs/parseargs/index.js +0 -263
- package/generators/node_modules/@pkgjs/parseargs/internal/errors.js +0 -55
- package/generators/node_modules/@pkgjs/parseargs/internal/primordials.js +0 -258
- package/generators/node_modules/@pkgjs/parseargs/internal/util.js +0 -24
- package/generators/node_modules/@pkgjs/parseargs/internal/validators.js +0 -61
- package/generators/node_modules/@pkgjs/parseargs/utils.js +0 -86
- package/generators/node_modules/ansi-regex/index.js +0 -5
- package/generators/node_modules/ansi-styles/index.js +0 -304
- package/generators/node_modules/balanced-match/index.js +0 -70
- package/generators/node_modules/brace-expansion/index.js +0 -153
- package/generators/node_modules/change-case/dist/index.js +0 -135
- package/generators/node_modules/change-case/dist/keys.js +0 -28
- package/generators/node_modules/color-convert/conversions.js +0 -840
- package/generators/node_modules/color-convert/index.js +0 -66
- package/generators/node_modules/color-convert/route.js +0 -81
- package/generators/node_modules/color-name/index.js +0 -757
- package/generators/node_modules/cross-spawn/index.js +0 -47
- package/generators/node_modules/cross-spawn/lib/enoent.js +0 -50
- package/generators/node_modules/cross-spawn/lib/parse.js +0 -91
- package/generators/node_modules/cross-spawn/lib/util/escape.js +0 -31
- package/generators/node_modules/cross-spawn/lib/util/readShebang.js +0 -37
- package/generators/node_modules/cross-spawn/lib/util/resolveCommand.js +0 -56
- package/generators/node_modules/eastasianwidth/eastasianwidth.js +0 -66
- package/generators/node_modules/emoji-regex/RGI_Emoji.js +0 -18
- package/generators/node_modules/emoji-regex/es2015/RGI_Emoji.js +0 -16
- package/generators/node_modules/emoji-regex/es2015/index.js +0 -16
- package/generators/node_modules/emoji-regex/es2015/text.js +0 -16
- package/generators/node_modules/emoji-regex/index.js +0 -18
- package/generators/node_modules/emoji-regex/text.js +0 -18
- package/generators/node_modules/flat/cli.js +0 -31
- package/generators/node_modules/flat/index.js +0 -83
- package/generators/node_modules/foreground-child/dist/cjs/all-signals.js +0 -30
- package/generators/node_modules/foreground-child/dist/cjs/index.js +0 -156
- package/generators/node_modules/foreground-child/dist/cjs/watchdog.js +0 -63
- package/generators/node_modules/foreground-child/dist/mjs/all-signals.js +0 -3
- package/generators/node_modules/foreground-child/dist/mjs/index.js +0 -111
- package/generators/node_modules/foreground-child/dist/mjs/watchdog.js +0 -39
- package/generators/node_modules/glob/dist/commonjs/glob.js +0 -205
- package/generators/node_modules/glob/dist/commonjs/has-magic.js +0 -33
- package/generators/node_modules/glob/dist/commonjs/ignore.js +0 -87
- package/generators/node_modules/glob/dist/commonjs/index.js +0 -114
- package/generators/node_modules/glob/dist/commonjs/pattern.js +0 -154
- package/generators/node_modules/glob/dist/commonjs/processor.js +0 -214
- package/generators/node_modules/glob/dist/commonjs/walker.js +0 -271
- package/generators/node_modules/glob/dist/esm/glob.js +0 -165
- package/generators/node_modules/glob/dist/esm/has-magic.js +0 -9
- package/generators/node_modules/glob/dist/esm/ignore.js +0 -59
- package/generators/node_modules/glob/dist/esm/index.js +0 -52
- package/generators/node_modules/glob/dist/esm/pattern.js +0 -130
- package/generators/node_modules/glob/dist/esm/processor.js +0 -187
- package/generators/node_modules/glob/dist/esm/walker.js +0 -237
- package/generators/node_modules/is-fullwidth-code-point/index.js +0 -22
- package/generators/node_modules/isexe/index.js +0 -64
- package/generators/node_modules/isexe/mode.js +0 -46
- package/generators/node_modules/isexe/test/basic.js +0 -229
- package/generators/node_modules/isexe/windows.js +0 -45
- package/generators/node_modules/jackspeak/dist/commonjs/index.js +0 -683
- package/generators/node_modules/jackspeak/dist/commonjs/parse-args.js +0 -65
- package/generators/node_modules/jackspeak/dist/esm/index.js +0 -640
- package/generators/node_modules/jackspeak/dist/esm/parse-args.js +0 -127
- package/generators/node_modules/lru-cache/dist/commonjs/index.js +0 -889
- package/generators/node_modules/lru-cache/dist/esm/index.js +0 -881
- package/generators/node_modules/minimatch/dist/cjs/assert-valid-pattern.js +0 -14
- package/generators/node_modules/minimatch/dist/cjs/ast.js +0 -389
- package/generators/node_modules/minimatch/dist/cjs/brace-expressions.js +0 -169
- package/generators/node_modules/minimatch/dist/cjs/escape.js +0 -10
- package/generators/node_modules/minimatch/dist/cjs/index.js +0 -680
- package/generators/node_modules/minimatch/dist/cjs/unescape.js +0 -10
- package/generators/node_modules/minimatch/dist/mjs/assert-valid-pattern.js +0 -6
- package/generators/node_modules/minimatch/dist/mjs/ast.js +0 -361
- package/generators/node_modules/minimatch/dist/mjs/brace-expressions.js +0 -161
- package/generators/node_modules/minimatch/dist/mjs/escape.js +0 -2
- package/generators/node_modules/minimatch/dist/mjs/index.js +0 -612
- package/generators/node_modules/minimatch/dist/mjs/unescape.js +0 -2
- package/generators/node_modules/minipass/dist/commonjs/index.js +0 -623
- package/generators/node_modules/minipass/dist/esm/index.js +0 -584
- package/generators/node_modules/path-key/index.js +0 -23
- package/generators/node_modules/path-scurry/dist/cjs/index.js +0 -1161
- package/generators/node_modules/path-scurry/dist/mjs/index.js +0 -1078
- package/generators/node_modules/shebang-command/index.js +0 -28
- package/generators/node_modules/shebang-regex/index.js +0 -16
- package/generators/node_modules/signal-exit/dist/cjs/browser.js +0 -14
- package/generators/node_modules/signal-exit/dist/cjs/index.js +0 -176
- package/generators/node_modules/signal-exit/dist/cjs/signals.js +0 -14
- package/generators/node_modules/signal-exit/dist/mjs/browser.js +0 -4
- package/generators/node_modules/signal-exit/dist/mjs/index.js +0 -146
- package/generators/node_modules/signal-exit/dist/mjs/signals.js +0 -5
- package/generators/node_modules/string-width/index.js +0 -34
- package/generators/node_modules/string-width-cjs/index.js +0 -49
- package/generators/node_modules/string-width-cjs/node_modules/ansi-regex/index.js +0 -19
- package/generators/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/index.js +0 -16
- package/generators/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/text.js +0 -16
- package/generators/node_modules/string-width-cjs/node_modules/emoji-regex/index.js +0 -18
- package/generators/node_modules/string-width-cjs/node_modules/emoji-regex/text.js +0 -18
- package/generators/node_modules/string-width-cjs/node_modules/strip-ansi/index.js +0 -21
- package/generators/node_modules/strip-ansi/index.js +0 -7
- package/generators/node_modules/strip-ansi-cjs/index.js +0 -21
- package/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/index.js +0 -19
- package/generators/node_modules/which/which.js +0 -108
- package/generators/node_modules/wrap-ansi/index.js +0 -134
- package/generators/node_modules/wrap-ansi-cjs/index.js +0 -158
- package/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/index.js +0 -19
- package/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/index.js +0 -281
- package/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/es2015/index.js +0 -16
- package/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/es2015/text.js +0 -16
- package/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/index.js +0 -18
- package/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/text.js +0 -18
- package/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/index.js +0 -49
- package/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/index.js +0 -21
- package/src/generators/node_modules/.package-lock.json +0 -458
- package/src/generators/node_modules/@isaacs/cliui/LICENSE.txt +0 -14
- package/src/generators/node_modules/@isaacs/cliui/README.md +0 -143
- package/src/generators/node_modules/@isaacs/cliui/build/index.cjs +0 -317
- package/src/generators/node_modules/@isaacs/cliui/build/index.d.cts +0 -43
- package/src/generators/node_modules/@isaacs/cliui/build/lib/index.js +0 -302
- package/src/generators/node_modules/@isaacs/cliui/index.mjs +0 -14
- package/src/generators/node_modules/@isaacs/cliui/package.json +0 -86
- package/src/generators/node_modules/@pkgjs/parseargs/.editorconfig +0 -14
- package/src/generators/node_modules/@pkgjs/parseargs/CHANGELOG.md +0 -147
- package/src/generators/node_modules/@pkgjs/parseargs/LICENSE +0 -201
- package/src/generators/node_modules/@pkgjs/parseargs/README.md +0 -413
- package/src/generators/node_modules/@pkgjs/parseargs/examples/is-default-value.js +0 -25
- package/src/generators/node_modules/@pkgjs/parseargs/examples/limit-long-syntax.js +0 -35
- package/src/generators/node_modules/@pkgjs/parseargs/examples/negate.js +0 -43
- package/src/generators/node_modules/@pkgjs/parseargs/examples/no-repeated-options.js +0 -31
- package/src/generators/node_modules/@pkgjs/parseargs/examples/ordered-options.mjs +0 -41
- package/src/generators/node_modules/@pkgjs/parseargs/examples/simple-hard-coded.js +0 -26
- package/src/generators/node_modules/@pkgjs/parseargs/index.js +0 -396
- package/src/generators/node_modules/@pkgjs/parseargs/internal/errors.js +0 -47
- package/src/generators/node_modules/@pkgjs/parseargs/internal/primordials.js +0 -393
- package/src/generators/node_modules/@pkgjs/parseargs/internal/util.js +0 -14
- package/src/generators/node_modules/@pkgjs/parseargs/internal/validators.js +0 -89
- package/src/generators/node_modules/@pkgjs/parseargs/package.json +0 -36
- package/src/generators/node_modules/@pkgjs/parseargs/utils.js +0 -198
- package/src/generators/node_modules/ansi-regex/index.d.ts +0 -33
- package/src/generators/node_modules/ansi-regex/index.js +0 -8
- package/src/generators/node_modules/ansi-regex/license +0 -9
- package/src/generators/node_modules/ansi-regex/package.json +0 -58
- package/src/generators/node_modules/ansi-regex/readme.md +0 -72
- package/src/generators/node_modules/ansi-styles/index.d.ts +0 -236
- package/src/generators/node_modules/ansi-styles/index.js +0 -223
- package/src/generators/node_modules/ansi-styles/license +0 -9
- package/src/generators/node_modules/ansi-styles/package.json +0 -54
- package/src/generators/node_modules/ansi-styles/readme.md +0 -173
- package/src/generators/node_modules/balanced-match/.github/FUNDING.yml +0 -2
- package/src/generators/node_modules/balanced-match/LICENSE.md +0 -21
- package/src/generators/node_modules/balanced-match/README.md +0 -97
- package/src/generators/node_modules/balanced-match/index.js +0 -62
- package/src/generators/node_modules/balanced-match/package.json +0 -48
- package/src/generators/node_modules/brace-expansion/.github/FUNDING.yml +0 -2
- package/src/generators/node_modules/brace-expansion/LICENSE +0 -21
- package/src/generators/node_modules/brace-expansion/README.md +0 -135
- package/src/generators/node_modules/brace-expansion/index.js +0 -203
- package/src/generators/node_modules/brace-expansion/package.json +0 -46
- package/src/generators/node_modules/change-case/README.md +0 -78
- package/src/generators/node_modules/change-case/dist/index.d.ts +0 -78
- package/src/generators/node_modules/change-case/dist/index.js +0 -206
- package/src/generators/node_modules/change-case/dist/index.js.map +0 -1
- package/src/generators/node_modules/change-case/dist/keys.d.ts +0 -11
- package/src/generators/node_modules/change-case/dist/keys.js +0 -31
- package/src/generators/node_modules/change-case/dist/keys.js.map +0 -1
- package/src/generators/node_modules/change-case/package.json +0 -56
- package/src/generators/node_modules/color-convert/CHANGELOG.md +0 -54
- package/src/generators/node_modules/color-convert/LICENSE +0 -21
- package/src/generators/node_modules/color-convert/README.md +0 -68
- package/src/generators/node_modules/color-convert/conversions.js +0 -839
- package/src/generators/node_modules/color-convert/index.js +0 -81
- package/src/generators/node_modules/color-convert/package.json +0 -48
- package/src/generators/node_modules/color-convert/route.js +0 -97
- package/src/generators/node_modules/color-name/LICENSE +0 -8
- package/src/generators/node_modules/color-name/README.md +0 -11
- package/src/generators/node_modules/color-name/index.js +0 -152
- package/src/generators/node_modules/color-name/package.json +0 -28
- package/src/generators/node_modules/cross-spawn/CHANGELOG.md +0 -130
- package/src/generators/node_modules/cross-spawn/LICENSE +0 -21
- package/src/generators/node_modules/cross-spawn/README.md +0 -96
- package/src/generators/node_modules/cross-spawn/index.js +0 -39
- package/src/generators/node_modules/cross-spawn/lib/enoent.js +0 -59
- package/src/generators/node_modules/cross-spawn/lib/parse.js +0 -91
- package/src/generators/node_modules/cross-spawn/lib/util/escape.js +0 -45
- package/src/generators/node_modules/cross-spawn/lib/util/readShebang.js +0 -23
- package/src/generators/node_modules/cross-spawn/lib/util/resolveCommand.js +0 -52
- package/src/generators/node_modules/cross-spawn/package.json +0 -73
- package/src/generators/node_modules/eastasianwidth/README.md +0 -32
- package/src/generators/node_modules/eastasianwidth/eastasianwidth.js +0 -311
- package/src/generators/node_modules/eastasianwidth/package.json +0 -18
- package/src/generators/node_modules/emoji-regex/LICENSE-MIT.txt +0 -20
- package/src/generators/node_modules/emoji-regex/README.md +0 -137
- package/src/generators/node_modules/emoji-regex/RGI_Emoji.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/RGI_Emoji.js +0 -6
- package/src/generators/node_modules/emoji-regex/es2015/RGI_Emoji.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/es2015/RGI_Emoji.js +0 -6
- package/src/generators/node_modules/emoji-regex/es2015/index.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/es2015/index.js +0 -6
- package/src/generators/node_modules/emoji-regex/es2015/text.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/es2015/text.js +0 -6
- package/src/generators/node_modules/emoji-regex/index.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/index.js +0 -6
- package/src/generators/node_modules/emoji-regex/package.json +0 -52
- package/src/generators/node_modules/emoji-regex/text.d.ts +0 -5
- package/src/generators/node_modules/emoji-regex/text.js +0 -6
- package/src/generators/node_modules/flat/LICENSE +0 -12
- package/src/generators/node_modules/flat/README.md +0 -234
- package/src/generators/node_modules/flat/cli.js +0 -40
- package/src/generators/node_modules/flat/index.d.ts +0 -17
- package/src/generators/node_modules/flat/index.js +0 -157
- package/src/generators/node_modules/flat/package.json +0 -49
- package/src/generators/node_modules/foreground-child/LICENSE +0 -15
- package/src/generators/node_modules/foreground-child/README.md +0 -90
- package/src/generators/node_modules/foreground-child/dist/cjs/all-signals.d.ts +0 -3
- package/src/generators/node_modules/foreground-child/dist/cjs/all-signals.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/cjs/all-signals.js +0 -58
- package/src/generators/node_modules/foreground-child/dist/cjs/all-signals.js.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/cjs/index.d.ts +0 -54
- package/src/generators/node_modules/foreground-child/dist/cjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/cjs/index.js +0 -154
- package/src/generators/node_modules/foreground-child/dist/cjs/index.js.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/cjs/package.json +0 -3
- package/src/generators/node_modules/foreground-child/dist/cjs/watchdog.d.ts +0 -4
- package/src/generators/node_modules/foreground-child/dist/cjs/watchdog.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/cjs/watchdog.js +0 -43
- package/src/generators/node_modules/foreground-child/dist/cjs/watchdog.js.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/all-signals.d.ts +0 -3
- package/src/generators/node_modules/foreground-child/dist/mjs/all-signals.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/all-signals.js +0 -52
- package/src/generators/node_modules/foreground-child/dist/mjs/all-signals.js.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/index.d.ts +0 -54
- package/src/generators/node_modules/foreground-child/dist/mjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/index.js +0 -146
- package/src/generators/node_modules/foreground-child/dist/mjs/index.js.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/package.json +0 -3
- package/src/generators/node_modules/foreground-child/dist/mjs/watchdog.d.ts +0 -4
- package/src/generators/node_modules/foreground-child/dist/mjs/watchdog.d.ts.map +0 -1
- package/src/generators/node_modules/foreground-child/dist/mjs/watchdog.js +0 -39
- package/src/generators/node_modules/foreground-child/dist/mjs/watchdog.js.map +0 -1
- package/src/generators/node_modules/foreground-child/package.json +0 -83
- package/src/generators/node_modules/glob/LICENSE +0 -15
- package/src/generators/node_modules/glob/README.md +0 -1214
- package/src/generators/node_modules/glob/dist/commonjs/glob.d.ts +0 -344
- package/src/generators/node_modules/glob/dist/commonjs/glob.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/glob.js +0 -243
- package/src/generators/node_modules/glob/dist/commonjs/glob.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/has-magic.d.ts +0 -14
- package/src/generators/node_modules/glob/dist/commonjs/has-magic.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/has-magic.js +0 -27
- package/src/generators/node_modules/glob/dist/commonjs/has-magic.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/ignore.d.ts +0 -20
- package/src/generators/node_modules/glob/dist/commonjs/ignore.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/ignore.js +0 -108
- package/src/generators/node_modules/glob/dist/commonjs/ignore.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/index.d.ts +0 -96
- package/src/generators/node_modules/glob/dist/commonjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/index.js +0 -68
- package/src/generators/node_modules/glob/dist/commonjs/index.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/package.json +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/pattern.d.ts +0 -77
- package/src/generators/node_modules/glob/dist/commonjs/pattern.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/pattern.js +0 -219
- package/src/generators/node_modules/glob/dist/commonjs/pattern.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/processor.d.ts +0 -59
- package/src/generators/node_modules/glob/dist/commonjs/processor.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/processor.js +0 -302
- package/src/generators/node_modules/glob/dist/commonjs/processor.js.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/walker.d.ts +0 -96
- package/src/generators/node_modules/glob/dist/commonjs/walker.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/commonjs/walker.js +0 -358
- package/src/generators/node_modules/glob/dist/commonjs/walker.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/bin.d.mts +0 -3
- package/src/generators/node_modules/glob/dist/esm/bin.d.mts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/bin.mjs +0 -275
- package/src/generators/node_modules/glob/dist/esm/bin.mjs.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/glob.d.ts +0 -344
- package/src/generators/node_modules/glob/dist/esm/glob.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/glob.js +0 -239
- package/src/generators/node_modules/glob/dist/esm/glob.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/has-magic.d.ts +0 -14
- package/src/generators/node_modules/glob/dist/esm/has-magic.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/has-magic.js +0 -23
- package/src/generators/node_modules/glob/dist/esm/has-magic.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/ignore.d.ts +0 -20
- package/src/generators/node_modules/glob/dist/esm/ignore.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/ignore.js +0 -104
- package/src/generators/node_modules/glob/dist/esm/ignore.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/index.d.ts +0 -96
- package/src/generators/node_modules/glob/dist/esm/index.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/index.js +0 -56
- package/src/generators/node_modules/glob/dist/esm/index.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/package.json +0 -1
- package/src/generators/node_modules/glob/dist/esm/pattern.d.ts +0 -77
- package/src/generators/node_modules/glob/dist/esm/pattern.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/pattern.js +0 -215
- package/src/generators/node_modules/glob/dist/esm/pattern.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/processor.d.ts +0 -59
- package/src/generators/node_modules/glob/dist/esm/processor.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/processor.js +0 -295
- package/src/generators/node_modules/glob/dist/esm/processor.js.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/walker.d.ts +0 -96
- package/src/generators/node_modules/glob/dist/esm/walker.d.ts.map +0 -1
- package/src/generators/node_modules/glob/dist/esm/walker.js +0 -352
- package/src/generators/node_modules/glob/dist/esm/walker.js.map +0 -1
- package/src/generators/node_modules/glob/package.json +0 -97
- package/src/generators/node_modules/is-fullwidth-code-point/index.d.ts +0 -17
- package/src/generators/node_modules/is-fullwidth-code-point/index.js +0 -50
- package/src/generators/node_modules/is-fullwidth-code-point/license +0 -9
- package/src/generators/node_modules/is-fullwidth-code-point/package.json +0 -42
- package/src/generators/node_modules/is-fullwidth-code-point/readme.md +0 -39
- package/src/generators/node_modules/isexe/LICENSE +0 -15
- package/src/generators/node_modules/isexe/README.md +0 -51
- package/src/generators/node_modules/isexe/index.js +0 -57
- package/src/generators/node_modules/isexe/mode.js +0 -41
- package/src/generators/node_modules/isexe/package.json +0 -31
- package/src/generators/node_modules/isexe/test/basic.js +0 -221
- package/src/generators/node_modules/isexe/windows.js +0 -42
- package/src/generators/node_modules/jackspeak/LICENSE.md +0 -55
- package/src/generators/node_modules/jackspeak/README.md +0 -348
- package/src/generators/node_modules/jackspeak/dist/commonjs/index.d.ts +0 -292
- package/src/generators/node_modules/jackspeak/dist/commonjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/index.js +0 -850
- package/src/generators/node_modules/jackspeak/dist/commonjs/index.js.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/package.json +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args-cjs.cjs.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args-cjs.d.cts.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args.d.ts +0 -4
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args.d.ts.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args.js +0 -50
- package/src/generators/node_modules/jackspeak/dist/commonjs/parse-args.js.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/esm/index.d.ts +0 -292
- package/src/generators/node_modules/jackspeak/dist/esm/index.d.ts.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/esm/index.js +0 -840
- package/src/generators/node_modules/jackspeak/dist/esm/index.js.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/esm/package.json +0 -1
- package/src/generators/node_modules/jackspeak/dist/esm/parse-args.d.ts +0 -4
- package/src/generators/node_modules/jackspeak/dist/esm/parse-args.d.ts.map +0 -1
- package/src/generators/node_modules/jackspeak/dist/esm/parse-args.js +0 -26
- package/src/generators/node_modules/jackspeak/dist/esm/parse-args.js.map +0 -1
- package/src/generators/node_modules/jackspeak/package.json +0 -94
- package/src/generators/node_modules/lru-cache/LICENSE +0 -15
- package/src/generators/node_modules/lru-cache/README.md +0 -1204
- package/src/generators/node_modules/lru-cache/dist/commonjs/index.d.ts +0 -851
- package/src/generators/node_modules/lru-cache/dist/commonjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/lru-cache/dist/commonjs/index.js +0 -1441
- package/src/generators/node_modules/lru-cache/dist/commonjs/index.js.map +0 -1
- package/src/generators/node_modules/lru-cache/dist/commonjs/package.json +0 -3
- package/src/generators/node_modules/lru-cache/dist/esm/index.d.ts +0 -851
- package/src/generators/node_modules/lru-cache/dist/esm/index.d.ts.map +0 -1
- package/src/generators/node_modules/lru-cache/dist/esm/index.js +0 -1437
- package/src/generators/node_modules/lru-cache/dist/esm/index.js.map +0 -1
- package/src/generators/node_modules/lru-cache/dist/esm/package.json +0 -3
- package/src/generators/node_modules/lru-cache/package.json +0 -118
- package/src/generators/node_modules/minimatch/LICENSE +0 -15
- package/src/generators/node_modules/minimatch/README.md +0 -454
- package/src/generators/node_modules/minimatch/dist/cjs/assert-valid-pattern.d.ts +0 -2
- package/src/generators/node_modules/minimatch/dist/cjs/assert-valid-pattern.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/assert-valid-pattern.js +0 -14
- package/src/generators/node_modules/minimatch/dist/cjs/assert-valid-pattern.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/ast.d.ts +0 -19
- package/src/generators/node_modules/minimatch/dist/cjs/ast.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/ast.js +0 -589
- package/src/generators/node_modules/minimatch/dist/cjs/ast.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/brace-expressions.d.ts +0 -8
- package/src/generators/node_modules/minimatch/dist/cjs/brace-expressions.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/brace-expressions.js +0 -152
- package/src/generators/node_modules/minimatch/dist/cjs/brace-expressions.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/escape.d.ts +0 -12
- package/src/generators/node_modules/minimatch/dist/cjs/escape.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/escape.js +0 -22
- package/src/generators/node_modules/minimatch/dist/cjs/escape.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/index.d.ts +0 -94
- package/src/generators/node_modules/minimatch/dist/cjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/index.js +0 -1011
- package/src/generators/node_modules/minimatch/dist/cjs/index.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/package.json +0 -3
- package/src/generators/node_modules/minimatch/dist/cjs/unescape.d.ts +0 -17
- package/src/generators/node_modules/minimatch/dist/cjs/unescape.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/cjs/unescape.js +0 -24
- package/src/generators/node_modules/minimatch/dist/cjs/unescape.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/assert-valid-pattern.d.ts +0 -2
- package/src/generators/node_modules/minimatch/dist/mjs/assert-valid-pattern.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/assert-valid-pattern.js +0 -10
- package/src/generators/node_modules/minimatch/dist/mjs/assert-valid-pattern.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/ast.d.ts +0 -19
- package/src/generators/node_modules/minimatch/dist/mjs/ast.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/ast.js +0 -585
- package/src/generators/node_modules/minimatch/dist/mjs/ast.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/brace-expressions.d.ts +0 -8
- package/src/generators/node_modules/minimatch/dist/mjs/brace-expressions.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/brace-expressions.js +0 -148
- package/src/generators/node_modules/minimatch/dist/mjs/brace-expressions.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/escape.d.ts +0 -12
- package/src/generators/node_modules/minimatch/dist/mjs/escape.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/escape.js +0 -18
- package/src/generators/node_modules/minimatch/dist/mjs/escape.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/index.d.ts +0 -94
- package/src/generators/node_modules/minimatch/dist/mjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/index.js +0 -995
- package/src/generators/node_modules/minimatch/dist/mjs/index.js.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/package.json +0 -3
- package/src/generators/node_modules/minimatch/dist/mjs/unescape.d.ts +0 -17
- package/src/generators/node_modules/minimatch/dist/mjs/unescape.d.ts.map +0 -1
- package/src/generators/node_modules/minimatch/dist/mjs/unescape.js +0 -20
- package/src/generators/node_modules/minimatch/dist/mjs/unescape.js.map +0 -1
- package/src/generators/node_modules/minimatch/package.json +0 -86
- package/src/generators/node_modules/minipass/LICENSE +0 -15
- package/src/generators/node_modules/minipass/README.md +0 -825
- package/src/generators/node_modules/minipass/dist/commonjs/index.d.ts +0 -549
- package/src/generators/node_modules/minipass/dist/commonjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/minipass/dist/commonjs/index.js +0 -1028
- package/src/generators/node_modules/minipass/dist/commonjs/index.js.map +0 -1
- package/src/generators/node_modules/minipass/dist/commonjs/package.json +0 -1
- package/src/generators/node_modules/minipass/dist/esm/index.d.ts +0 -549
- package/src/generators/node_modules/minipass/dist/esm/index.d.ts.map +0 -1
- package/src/generators/node_modules/minipass/dist/esm/index.js +0 -1018
- package/src/generators/node_modules/minipass/dist/esm/index.js.map +0 -1
- package/src/generators/node_modules/minipass/dist/esm/package.json +0 -1
- package/src/generators/node_modules/minipass/package.json +0 -82
- package/src/generators/node_modules/path-key/index.d.ts +0 -40
- package/src/generators/node_modules/path-key/index.js +0 -16
- package/src/generators/node_modules/path-key/license +0 -9
- package/src/generators/node_modules/path-key/package.json +0 -39
- package/src/generators/node_modules/path-key/readme.md +0 -61
- package/src/generators/node_modules/path-scurry/LICENSE.md +0 -55
- package/src/generators/node_modules/path-scurry/README.md +0 -631
- package/src/generators/node_modules/path-scurry/dist/cjs/index.d.ts +0 -1107
- package/src/generators/node_modules/path-scurry/dist/cjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/path-scurry/dist/cjs/index.js +0 -2018
- package/src/generators/node_modules/path-scurry/dist/cjs/index.js.map +0 -1
- package/src/generators/node_modules/path-scurry/dist/cjs/package.json +0 -3
- package/src/generators/node_modules/path-scurry/dist/mjs/index.d.ts +0 -1107
- package/src/generators/node_modules/path-scurry/dist/mjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/path-scurry/dist/mjs/index.js +0 -1983
- package/src/generators/node_modules/path-scurry/dist/mjs/index.js.map +0 -1
- package/src/generators/node_modules/path-scurry/dist/mjs/package.json +0 -3
- package/src/generators/node_modules/path-scurry/package.json +0 -87
- package/src/generators/node_modules/shebang-command/index.js +0 -19
- package/src/generators/node_modules/shebang-command/license +0 -9
- package/src/generators/node_modules/shebang-command/package.json +0 -34
- package/src/generators/node_modules/shebang-command/readme.md +0 -34
- package/src/generators/node_modules/shebang-regex/index.d.ts +0 -22
- package/src/generators/node_modules/shebang-regex/index.js +0 -2
- package/src/generators/node_modules/shebang-regex/license +0 -9
- package/src/generators/node_modules/shebang-regex/package.json +0 -35
- package/src/generators/node_modules/shebang-regex/readme.md +0 -33
- package/src/generators/node_modules/signal-exit/LICENSE.txt +0 -16
- package/src/generators/node_modules/signal-exit/README.md +0 -74
- package/src/generators/node_modules/signal-exit/dist/cjs/browser.d.ts +0 -12
- package/src/generators/node_modules/signal-exit/dist/cjs/browser.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/cjs/browser.js +0 -10
- package/src/generators/node_modules/signal-exit/dist/cjs/browser.js.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/cjs/index.d.ts +0 -48
- package/src/generators/node_modules/signal-exit/dist/cjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/cjs/index.js +0 -279
- package/src/generators/node_modules/signal-exit/dist/cjs/index.js.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/cjs/package.json +0 -3
- package/src/generators/node_modules/signal-exit/dist/cjs/signals.d.ts +0 -29
- package/src/generators/node_modules/signal-exit/dist/cjs/signals.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/cjs/signals.js +0 -42
- package/src/generators/node_modules/signal-exit/dist/cjs/signals.js.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/browser.d.ts +0 -12
- package/src/generators/node_modules/signal-exit/dist/mjs/browser.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/browser.js +0 -4
- package/src/generators/node_modules/signal-exit/dist/mjs/browser.js.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/index.d.ts +0 -48
- package/src/generators/node_modules/signal-exit/dist/mjs/index.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/index.js +0 -275
- package/src/generators/node_modules/signal-exit/dist/mjs/index.js.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/package.json +0 -3
- package/src/generators/node_modules/signal-exit/dist/mjs/signals.d.ts +0 -29
- package/src/generators/node_modules/signal-exit/dist/mjs/signals.d.ts.map +0 -1
- package/src/generators/node_modules/signal-exit/dist/mjs/signals.js +0 -39
- package/src/generators/node_modules/signal-exit/dist/mjs/signals.js.map +0 -1
- package/src/generators/node_modules/signal-exit/package.json +0 -106
- package/src/generators/node_modules/string-width/index.d.ts +0 -29
- package/src/generators/node_modules/string-width/index.js +0 -54
- package/src/generators/node_modules/string-width/license +0 -9
- package/src/generators/node_modules/string-width/package.json +0 -59
- package/src/generators/node_modules/string-width/readme.md +0 -67
- package/src/generators/node_modules/string-width-cjs/index.d.ts +0 -29
- package/src/generators/node_modules/string-width-cjs/index.js +0 -47
- package/src/generators/node_modules/string-width-cjs/license +0 -9
- package/src/generators/node_modules/string-width-cjs/node_modules/ansi-regex/index.d.ts +0 -37
- package/src/generators/node_modules/string-width-cjs/node_modules/ansi-regex/index.js +0 -10
- package/src/generators/node_modules/string-width-cjs/node_modules/ansi-regex/license +0 -9
- package/src/generators/node_modules/string-width-cjs/node_modules/ansi-regex/package.json +0 -55
- package/src/generators/node_modules/string-width-cjs/node_modules/ansi-regex/readme.md +0 -78
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/LICENSE-MIT.txt +0 -20
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/README.md +0 -73
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/index.js +0 -6
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/es2015/text.js +0 -6
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/index.d.ts +0 -23
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/index.js +0 -6
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/package.json +0 -50
- package/src/generators/node_modules/string-width-cjs/node_modules/emoji-regex/text.js +0 -6
- package/src/generators/node_modules/string-width-cjs/node_modules/strip-ansi/index.d.ts +0 -17
- package/src/generators/node_modules/string-width-cjs/node_modules/strip-ansi/index.js +0 -4
- package/src/generators/node_modules/string-width-cjs/node_modules/strip-ansi/license +0 -9
- package/src/generators/node_modules/string-width-cjs/node_modules/strip-ansi/package.json +0 -54
- package/src/generators/node_modules/string-width-cjs/node_modules/strip-ansi/readme.md +0 -46
- package/src/generators/node_modules/string-width-cjs/package.json +0 -56
- package/src/generators/node_modules/string-width-cjs/readme.md +0 -50
- package/src/generators/node_modules/strip-ansi/index.d.ts +0 -15
- package/src/generators/node_modules/strip-ansi/index.js +0 -14
- package/src/generators/node_modules/strip-ansi/license +0 -9
- package/src/generators/node_modules/strip-ansi/package.json +0 -57
- package/src/generators/node_modules/strip-ansi/readme.md +0 -41
- package/src/generators/node_modules/strip-ansi-cjs/index.d.ts +0 -17
- package/src/generators/node_modules/strip-ansi-cjs/index.js +0 -4
- package/src/generators/node_modules/strip-ansi-cjs/license +0 -9
- package/src/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/index.d.ts +0 -37
- package/src/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/index.js +0 -10
- package/src/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/license +0 -9
- package/src/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/package.json +0 -55
- package/src/generators/node_modules/strip-ansi-cjs/node_modules/ansi-regex/readme.md +0 -78
- package/src/generators/node_modules/strip-ansi-cjs/package.json +0 -54
- package/src/generators/node_modules/strip-ansi-cjs/readme.md +0 -46
- package/src/generators/node_modules/which/CHANGELOG.md +0 -166
- package/src/generators/node_modules/which/LICENSE +0 -15
- package/src/generators/node_modules/which/README.md +0 -54
- package/src/generators/node_modules/which/bin/node-which +0 -52
- package/src/generators/node_modules/which/package.json +0 -43
- package/src/generators/node_modules/which/which.js +0 -125
- package/src/generators/node_modules/wrap-ansi/index.d.ts +0 -41
- package/src/generators/node_modules/wrap-ansi/index.js +0 -214
- package/src/generators/node_modules/wrap-ansi/license +0 -9
- package/src/generators/node_modules/wrap-ansi/package.json +0 -69
- package/src/generators/node_modules/wrap-ansi/readme.md +0 -91
- package/src/generators/node_modules/wrap-ansi-cjs/index.js +0 -216
- package/src/generators/node_modules/wrap-ansi-cjs/license +0 -9
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/index.d.ts +0 -37
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/index.js +0 -10
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/license +0 -9
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/package.json +0 -55
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-regex/readme.md +0 -78
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/index.d.ts +0 -345
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/index.js +0 -163
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/license +0 -9
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/package.json +0 -56
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/ansi-styles/readme.md +0 -152
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/LICENSE-MIT.txt +0 -20
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/README.md +0 -73
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/es2015/index.js +0 -6
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/es2015/text.js +0 -6
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/index.d.ts +0 -23
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/index.js +0 -6
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/package.json +0 -50
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/emoji-regex/text.js +0 -6
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/index.d.ts +0 -29
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/index.js +0 -47
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/license +0 -9
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/package.json +0 -56
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/string-width/readme.md +0 -50
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/index.d.ts +0 -17
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/index.js +0 -4
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/license +0 -9
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/package.json +0 -54
- package/src/generators/node_modules/wrap-ansi-cjs/node_modules/strip-ansi/readme.md +0 -46
- package/src/generators/node_modules/wrap-ansi-cjs/package.json +0 -62
- package/src/generators/node_modules/wrap-ansi-cjs/readme.md +0 -91
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
/// <reference types="node" />
|
|
3
|
-
import { ChildProcess, SpawnOptions } from 'child_process';
|
|
4
|
-
/**
|
|
5
|
-
* The signature for the cleanup method.
|
|
6
|
-
*
|
|
7
|
-
* Arguments indicate the exit status of the child process.
|
|
8
|
-
*
|
|
9
|
-
* If a Promise is returned, then the process is not terminated
|
|
10
|
-
* until it resolves, and the resolution value is treated as the
|
|
11
|
-
* exit status (if a number) or signal exit (if a signal string).
|
|
12
|
-
*
|
|
13
|
-
* If `undefined` is returned, then no change is made, and the parent
|
|
14
|
-
* exits in the same way that the child exited.
|
|
15
|
-
*
|
|
16
|
-
* If boolean `false` is returned, then the parent's exit is canceled.
|
|
17
|
-
*
|
|
18
|
-
* If a number is returned, then the parent process exits with the number
|
|
19
|
-
* as its exitCode.
|
|
20
|
-
*
|
|
21
|
-
* If a signal string is returned, then the parent process is killed with
|
|
22
|
-
* the same signal that caused the child to exit.
|
|
23
|
-
*/
|
|
24
|
-
export type Cleanup = (code: number | null, signal: null | NodeJS.Signals) => void | undefined | number | NodeJS.Signals | false | Promise<void | undefined | number | NodeJS.Signals | false>;
|
|
25
|
-
export type FgArgs = [program: string | string[], cleanup?: Cleanup] | [program: string[], opts?: SpawnOptions, cleanup?: Cleanup] | [program: string, cleanup?: Cleanup] | [program: string, opts?: SpawnOptions, cleanup?: Cleanup] | [program: string, args?: string[], cleanup?: Cleanup] | [
|
|
26
|
-
program: string,
|
|
27
|
-
args?: string[],
|
|
28
|
-
opts?: SpawnOptions,
|
|
29
|
-
cleanup?: Cleanup
|
|
30
|
-
];
|
|
31
|
-
/**
|
|
32
|
-
* Normalizes the arguments passed to `foregroundChild`.
|
|
33
|
-
*
|
|
34
|
-
* Exposed for testing.
|
|
35
|
-
*
|
|
36
|
-
* @internal
|
|
37
|
-
*/
|
|
38
|
-
export declare const normalizeFgArgs: (fgArgs: FgArgs) => [program: string, args: string[], spawnOpts: SpawnOptions, cleanup: Cleanup];
|
|
39
|
-
/**
|
|
40
|
-
* Spawn the specified program as a "foreground" process, or at least as
|
|
41
|
-
* close as is possible given node's lack of exec-without-fork.
|
|
42
|
-
*
|
|
43
|
-
* Cleanup method may be used to modify or ignore the result of the child's
|
|
44
|
-
* exit code or signal. If cleanup returns undefined (or a Promise that
|
|
45
|
-
* resolves to undefined), then the parent will exit in the same way that
|
|
46
|
-
* the child did.
|
|
47
|
-
*
|
|
48
|
-
* Return boolean `false` to prevent the parent's exit entirely.
|
|
49
|
-
*/
|
|
50
|
-
export declare function foregroundChild(cmd: string | string[], cleanup?: Cleanup): ChildProcess;
|
|
51
|
-
export declare function foregroundChild(program: string, args?: string[], cleanup?: Cleanup): ChildProcess;
|
|
52
|
-
export declare function foregroundChild(program: string, spawnOpts?: SpawnOptions, cleanup?: Cleanup): ChildProcess;
|
|
53
|
-
export declare function foregroundChild(program: string, args?: string[], spawnOpts?: SpawnOptions, cleanup?: Cleanup): ChildProcess;
|
|
54
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;AAAA,OAAO,EACL,YAAY,EAIZ,YAAY,EACb,MAAM,eAAe,CAAA;AAUtB;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,MAAM,OAAO,GAAG,CACpB,IAAI,EAAE,MAAM,GAAG,IAAI,EACnB,MAAM,EAAE,IAAI,GAAG,MAAM,CAAC,OAAO,KAE3B,IAAI,GACJ,SAAS,GACT,MAAM,GACN,MAAM,CAAC,OAAO,GACd,KAAK,GACL,OAAO,CAAC,IAAI,GAAG,SAAS,GAAG,MAAM,GAAG,MAAM,CAAC,OAAO,GAAG,KAAK,CAAC,CAAA;AAE/D,MAAM,MAAM,MAAM,GACd,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,GAC/C,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,IAAI,CAAC,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,GAC3D,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,GACpC,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,GACzD,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,GACrD;IACE,OAAO,EAAE,MAAM;IACf,IAAI,CAAC,EAAE,MAAM,EAAE;IACf,IAAI,CAAC,EAAE,YAAY;IACnB,OAAO,CAAC,EAAE,OAAO;CAClB,CAAA;AAEL;;;;;;GAMG;AACH,eAAO,MAAM,eAAe,WAClB,MAAM,iFA0Bf,CAAA;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,EACtB,OAAO,CAAC,EAAE,OAAO,GAChB,YAAY,CAAA;AACf,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,EACf,IAAI,CAAC,EAAE,MAAM,EAAE,EACf,OAAO,CAAC,EAAE,OAAO,GAChB,YAAY,CAAA;AACf,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,EACf,SAAS,CAAC,EAAE,YAAY,EACxB,OAAO,CAAC,EAAE,OAAO,GAChB,YAAY,CAAA;AACf,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,EACf,IAAI,CAAC,EAAE,MAAM,EAAE,EACf,SAAS,CAAC,EAAE,YAAY,EACxB,OAAO,CAAC,EAAE,OAAO,GAChB,YAAY,CAAA"}
|
|
@@ -1,146 +0,0 @@
|
|
|
1
|
-
import { spawn as nodeSpawn, } from 'child_process';
|
|
2
|
-
import crossSpawn from 'cross-spawn';
|
|
3
|
-
import { onExit } from 'signal-exit';
|
|
4
|
-
import { allSignals } from './all-signals.js';
|
|
5
|
-
import { watchdog } from './watchdog.js';
|
|
6
|
-
/* c8 ignore start */
|
|
7
|
-
const spawn = process?.platform === 'win32' ? crossSpawn : nodeSpawn;
|
|
8
|
-
/**
|
|
9
|
-
* Normalizes the arguments passed to `foregroundChild`.
|
|
10
|
-
*
|
|
11
|
-
* Exposed for testing.
|
|
12
|
-
*
|
|
13
|
-
* @internal
|
|
14
|
-
*/
|
|
15
|
-
export const normalizeFgArgs = (fgArgs) => {
|
|
16
|
-
let [program, args = [], spawnOpts = {}, cleanup = () => { }] = fgArgs;
|
|
17
|
-
if (typeof args === 'function') {
|
|
18
|
-
cleanup = args;
|
|
19
|
-
spawnOpts = {};
|
|
20
|
-
args = [];
|
|
21
|
-
}
|
|
22
|
-
else if (!!args && typeof args === 'object' && !Array.isArray(args)) {
|
|
23
|
-
if (typeof spawnOpts === 'function')
|
|
24
|
-
cleanup = spawnOpts;
|
|
25
|
-
spawnOpts = args;
|
|
26
|
-
args = [];
|
|
27
|
-
}
|
|
28
|
-
else if (typeof spawnOpts === 'function') {
|
|
29
|
-
cleanup = spawnOpts;
|
|
30
|
-
spawnOpts = {};
|
|
31
|
-
}
|
|
32
|
-
if (Array.isArray(program)) {
|
|
33
|
-
const [pp, ...pa] = program;
|
|
34
|
-
program = pp;
|
|
35
|
-
args = pa;
|
|
36
|
-
}
|
|
37
|
-
return [program, args, { ...spawnOpts }, cleanup];
|
|
38
|
-
};
|
|
39
|
-
export function foregroundChild(...fgArgs) {
|
|
40
|
-
const [program, args, spawnOpts, cleanup] = normalizeFgArgs(fgArgs);
|
|
41
|
-
spawnOpts.stdio = [0, 1, 2];
|
|
42
|
-
if (process.send) {
|
|
43
|
-
spawnOpts.stdio.push('ipc');
|
|
44
|
-
}
|
|
45
|
-
const child = spawn(program, args, spawnOpts);
|
|
46
|
-
const unproxySignals = proxySignals(child);
|
|
47
|
-
const childHangup = () => {
|
|
48
|
-
try {
|
|
49
|
-
child.kill('SIGHUP');
|
|
50
|
-
/* c8 ignore start */
|
|
51
|
-
}
|
|
52
|
-
catch (_) {
|
|
53
|
-
// SIGHUP is weird on windows
|
|
54
|
-
child.kill('SIGTERM');
|
|
55
|
-
}
|
|
56
|
-
/* c8 ignore stop */
|
|
57
|
-
};
|
|
58
|
-
const removeOnExit = onExit(childHangup);
|
|
59
|
-
const dog = watchdog(child);
|
|
60
|
-
let done = false;
|
|
61
|
-
child.on('close', async (code, signal) => {
|
|
62
|
-
dog.kill('SIGKILL');
|
|
63
|
-
/* c8 ignore start */
|
|
64
|
-
if (done) {
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
/* c8 ignore stop */
|
|
68
|
-
done = true;
|
|
69
|
-
const result = cleanup(code, signal);
|
|
70
|
-
const res = isPromise(result) ? await result : result;
|
|
71
|
-
removeOnExit();
|
|
72
|
-
unproxySignals();
|
|
73
|
-
if (res === false)
|
|
74
|
-
return;
|
|
75
|
-
else if (typeof res === 'string') {
|
|
76
|
-
signal = res;
|
|
77
|
-
code = null;
|
|
78
|
-
}
|
|
79
|
-
else if (typeof res === 'number') {
|
|
80
|
-
code = res;
|
|
81
|
-
signal = null;
|
|
82
|
-
}
|
|
83
|
-
if (signal) {
|
|
84
|
-
// If there is nothing else keeping the event loop alive,
|
|
85
|
-
// then there's a race between a graceful exit and getting
|
|
86
|
-
// the signal to this process. Put this timeout here to
|
|
87
|
-
// make sure we're still alive to get the signal, and thus
|
|
88
|
-
// exit with the intended signal code.
|
|
89
|
-
/* istanbul ignore next */
|
|
90
|
-
setTimeout(() => { }, 2000);
|
|
91
|
-
try {
|
|
92
|
-
process.kill(process.pid, signal);
|
|
93
|
-
/* c8 ignore start */
|
|
94
|
-
}
|
|
95
|
-
catch (_) {
|
|
96
|
-
process.kill(process.pid, 'SIGTERM');
|
|
97
|
-
}
|
|
98
|
-
/* c8 ignore stop */
|
|
99
|
-
}
|
|
100
|
-
else {
|
|
101
|
-
process.exit(code || 0);
|
|
102
|
-
}
|
|
103
|
-
});
|
|
104
|
-
if (process.send) {
|
|
105
|
-
process.removeAllListeners('message');
|
|
106
|
-
child.on('message', (message, sendHandle) => {
|
|
107
|
-
process.send?.(message, sendHandle);
|
|
108
|
-
});
|
|
109
|
-
process.on('message', (message, sendHandle) => {
|
|
110
|
-
child.send(message, sendHandle);
|
|
111
|
-
});
|
|
112
|
-
}
|
|
113
|
-
return child;
|
|
114
|
-
}
|
|
115
|
-
/**
|
|
116
|
-
* Starts forwarding signals to `child` through `parent`.
|
|
117
|
-
*/
|
|
118
|
-
const proxySignals = (child) => {
|
|
119
|
-
const listeners = new Map();
|
|
120
|
-
for (const sig of allSignals) {
|
|
121
|
-
const listener = () => {
|
|
122
|
-
// some signals can only be received, not sent
|
|
123
|
-
try {
|
|
124
|
-
child.kill(sig);
|
|
125
|
-
/* c8 ignore start */
|
|
126
|
-
}
|
|
127
|
-
catch (_) { }
|
|
128
|
-
/* c8 ignore stop */
|
|
129
|
-
};
|
|
130
|
-
try {
|
|
131
|
-
// if it's a signal this system doesn't recognize, skip it
|
|
132
|
-
process.on(sig, listener);
|
|
133
|
-
listeners.set(sig, listener);
|
|
134
|
-
/* c8 ignore start */
|
|
135
|
-
}
|
|
136
|
-
catch (_) { }
|
|
137
|
-
/* c8 ignore stop */
|
|
138
|
-
}
|
|
139
|
-
return () => {
|
|
140
|
-
for (const [sig, listener] of listeners) {
|
|
141
|
-
process.removeListener(sig, listener);
|
|
142
|
-
}
|
|
143
|
-
};
|
|
144
|
-
};
|
|
145
|
-
const isPromise = (o) => !!o && typeof o === 'object' && typeof o.then === 'function';
|
|
146
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"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","sourcesContent":["import {\n ChildProcess,\n SendHandle,\n Serializable,\n spawn as nodeSpawn,\n SpawnOptions,\n} from 'child_process'\nimport crossSpawn from 'cross-spawn'\nimport { onExit } from 'signal-exit'\nimport { allSignals } from './all-signals.js'\nimport { watchdog } from './watchdog.js'\n\n/* c8 ignore start */\nconst spawn = process?.platform === 'win32' ? crossSpawn : nodeSpawn\n/* c8 ignore stop */\n\n/**\n * The signature for the cleanup method.\n *\n * Arguments indicate the exit status of the child process.\n *\n * If a Promise is returned, then the process is not terminated\n * until it resolves, and the resolution value is treated as the\n * exit status (if a number) or signal exit (if a signal string).\n *\n * If `undefined` is returned, then no change is made, and the parent\n * exits in the same way that the child exited.\n *\n * If boolean `false` is returned, then the parent's exit is canceled.\n *\n * If a number is returned, then the parent process exits with the number\n * as its exitCode.\n *\n * If a signal string is returned, then the parent process is killed with\n * the same signal that caused the child to exit.\n */\nexport type Cleanup = (\n code: number | null,\n signal: null | NodeJS.Signals\n) =>\n | void\n | undefined\n | number\n | NodeJS.Signals\n | false\n | Promise<void | undefined | number | NodeJS.Signals | false>\n\nexport type FgArgs =\n | [program: string | string[], cleanup?: Cleanup]\n | [program: string[], opts?: SpawnOptions, cleanup?: Cleanup]\n | [program: string, cleanup?: Cleanup]\n | [program: string, opts?: SpawnOptions, cleanup?: Cleanup]\n | [program: string, args?: string[], cleanup?: Cleanup]\n | [\n program: string,\n args?: string[],\n opts?: SpawnOptions,\n cleanup?: Cleanup\n ]\n\n/**\n * Normalizes the arguments passed to `foregroundChild`.\n *\n * Exposed for testing.\n *\n * @internal\n */\nexport const normalizeFgArgs = (\n fgArgs: FgArgs\n): [\n program: string,\n args: string[],\n spawnOpts: SpawnOptions,\n cleanup: Cleanup\n] => {\n let [program, args = [], spawnOpts = {}, cleanup = () => {}] = fgArgs\n if (typeof args === 'function') {\n cleanup = args\n spawnOpts = {}\n args = []\n } else if (!!args && typeof args === 'object' && !Array.isArray(args)) {\n if (typeof spawnOpts === 'function') cleanup = spawnOpts\n spawnOpts = args\n args = []\n } else if (typeof spawnOpts === 'function') {\n cleanup = spawnOpts\n spawnOpts = {}\n }\n if (Array.isArray(program)) {\n const [pp, ...pa] = program\n program = pp\n args = pa\n }\n return [program, args, { ...spawnOpts }, cleanup]\n}\n\n/**\n * Spawn the specified program as a \"foreground\" process, or at least as\n * close as is possible given node's lack of exec-without-fork.\n *\n * Cleanup method may be used to modify or ignore the result of the child's\n * exit code or signal. If cleanup returns undefined (or a Promise that\n * resolves to undefined), then the parent will exit in the same way that\n * the child did.\n *\n * Return boolean `false` to prevent the parent's exit entirely.\n */\nexport function foregroundChild(\n cmd: string | string[],\n cleanup?: Cleanup\n): ChildProcess\nexport function foregroundChild(\n program: string,\n args?: string[],\n cleanup?: Cleanup\n): ChildProcess\nexport function foregroundChild(\n program: string,\n spawnOpts?: SpawnOptions,\n cleanup?: Cleanup\n): ChildProcess\nexport function foregroundChild(\n program: string,\n args?: string[],\n spawnOpts?: SpawnOptions,\n cleanup?: Cleanup\n): ChildProcess\nexport function foregroundChild(...fgArgs: FgArgs): ChildProcess {\n const [program, args, spawnOpts, cleanup] = normalizeFgArgs(fgArgs)\n\n spawnOpts.stdio = [0, 1, 2]\n if (process.send) {\n spawnOpts.stdio.push('ipc')\n }\n\n const child = spawn(program, args, spawnOpts)\n\n const unproxySignals = proxySignals(child)\n const childHangup = () => {\n try {\n child.kill('SIGHUP')\n\n /* c8 ignore start */\n } catch (_) {\n // SIGHUP is weird on windows\n child.kill('SIGTERM')\n }\n /* c8 ignore stop */\n }\n const removeOnExit = onExit(childHangup)\n\n const dog = watchdog(child)\n\n let done = false\n child.on('close', async (code, signal) => {\n dog.kill('SIGKILL')\n /* c8 ignore start */\n if (done) {\n return\n }\n /* c8 ignore stop */\n done = true\n const result = cleanup(code, signal)\n const res = isPromise(result) ? await result : result\n removeOnExit()\n unproxySignals()\n\n if (res === false) return\n else if (typeof res === 'string') {\n signal = res\n code = null\n } else if (typeof res === 'number') {\n code = res\n signal = null\n }\n\n if (signal) {\n // If there is nothing else keeping the event loop alive,\n // then there's a race between a graceful exit and getting\n // the signal to this process. Put this timeout here to\n // make sure we're still alive to get the signal, and thus\n // exit with the intended signal code.\n /* istanbul ignore next */\n setTimeout(() => {}, 2000)\n try {\n process.kill(process.pid, signal)\n /* c8 ignore start */\n } catch (_) {\n process.kill(process.pid, 'SIGTERM')\n }\n /* c8 ignore stop */\n } else {\n process.exit(code || 0)\n }\n })\n\n if (process.send) {\n process.removeAllListeners('message')\n\n child.on('message', (message, sendHandle) => {\n process.send?.(message, sendHandle)\n })\n\n process.on('message', (message, sendHandle) => {\n child.send(\n message as Serializable,\n sendHandle as SendHandle | undefined\n )\n })\n }\n\n return child\n}\n\n/**\n * Starts forwarding signals to `child` through `parent`.\n */\nconst proxySignals = (child: ChildProcess) => {\n const listeners = new Map()\n\n for (const sig of allSignals) {\n const listener = () => {\n // some signals can only be received, not sent\n try {\n child.kill(sig)\n /* c8 ignore start */\n } catch (_) {}\n /* c8 ignore stop */\n }\n try {\n // if it's a signal this system doesn't recognize, skip it\n process.on(sig, listener)\n listeners.set(sig, listener)\n /* c8 ignore start */\n } catch (_) {}\n /* c8 ignore stop */\n }\n\n return () => {\n for (const [sig, listener] of listeners) {\n process.removeListener(sig, listener)\n }\n }\n}\n\nconst isPromise = (o: any): o is Promise<any> =>\n !!o && typeof o === 'object' && typeof o.then === 'function'\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"watchdog.d.ts","sourceRoot":"","sources":["../../src/watchdog.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,YAAY,EAAS,MAAM,eAAe,CAAA;AAyBnD,eAAO,MAAM,QAAQ,UAAW,YAAY,iBAc3C,CAAA"}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
// this spawns a child process that listens for SIGHUP when the
|
|
2
|
-
// parent process exits, and after 200ms, sends a SIGKILL to the
|
|
3
|
-
// child, in case it did not terminate.
|
|
4
|
-
import { spawn } from 'child_process';
|
|
5
|
-
const watchdogCode = String.raw `
|
|
6
|
-
const pid = parseInt(process.argv[1], 10)
|
|
7
|
-
process.title = 'node (foreground-child watchdog pid=' + pid + ')'
|
|
8
|
-
if (!isNaN(pid)) {
|
|
9
|
-
let barked = false
|
|
10
|
-
// keepalive
|
|
11
|
-
const interval = setInterval(() => {}, 60000)
|
|
12
|
-
const bark = () => {
|
|
13
|
-
clearInterval(interval)
|
|
14
|
-
if (barked) return
|
|
15
|
-
barked = true
|
|
16
|
-
process.removeListener('SIGHUP', bark)
|
|
17
|
-
setTimeout(() => {
|
|
18
|
-
try {
|
|
19
|
-
process.kill(pid, 'SIGKILL')
|
|
20
|
-
setTimeout(() => process.exit(), 200)
|
|
21
|
-
} catch (_) {}
|
|
22
|
-
}, 500)
|
|
23
|
-
})
|
|
24
|
-
process.on('SIGHUP', bark)
|
|
25
|
-
}
|
|
26
|
-
`;
|
|
27
|
-
export const watchdog = (child) => {
|
|
28
|
-
let dogExited = false;
|
|
29
|
-
const dog = spawn(process.execPath, ['-e', watchdogCode, String(child.pid)], {
|
|
30
|
-
stdio: 'ignore',
|
|
31
|
-
});
|
|
32
|
-
dog.on('exit', () => (dogExited = true));
|
|
33
|
-
child.on('exit', () => {
|
|
34
|
-
if (!dogExited)
|
|
35
|
-
dog.kill('SIGTERM');
|
|
36
|
-
});
|
|
37
|
-
return dog;
|
|
38
|
-
};
|
|
39
|
-
//# sourceMappingURL=watchdog.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"watchdog.js","sourceRoot":"","sources":["../../src/watchdog.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,gEAAgE;AAChE,uCAAuC;AAEvC,OAAO,EAAgB,KAAK,EAAE,MAAM,eAAe,CAAA;AAEnD,MAAM,YAAY,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;CAqB9B,CAAA;AAED,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,KAAmB,EAAE,EAAE;IAC9C,IAAI,SAAS,GAAG,KAAK,CAAA;IACrB,MAAM,GAAG,GAAG,KAAK,CACf,OAAO,CAAC,QAAQ,EAChB,CAAC,IAAI,EAAE,YAAY,EAAE,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,EACvC;QACE,KAAK,EAAE,QAAQ;KAChB,CACF,CAAA;IACD,GAAG,CAAC,EAAE,CAAC,MAAM,EAAE,GAAG,EAAE,CAAC,CAAC,SAAS,GAAG,IAAI,CAAC,CAAC,CAAA;IACxC,KAAK,CAAC,EAAE,CAAC,MAAM,EAAE,GAAG,EAAE;QACpB,IAAI,CAAC,SAAS;YAAE,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,CAAA;IACrC,CAAC,CAAC,CAAA;IACF,OAAO,GAAG,CAAA;AACZ,CAAC,CAAA","sourcesContent":["// this spawns a child process that listens for SIGHUP when the\n// parent process exits, and after 200ms, sends a SIGKILL to the\n// child, in case it did not terminate.\n\nimport { ChildProcess, spawn } from 'child_process'\n\nconst watchdogCode = String.raw`\nconst pid = parseInt(process.argv[1], 10)\nprocess.title = 'node (foreground-child watchdog pid=' + pid + ')'\nif (!isNaN(pid)) {\n let barked = false\n // keepalive\n const interval = setInterval(() => {}, 60000)\n const bark = () => {\n clearInterval(interval)\n if (barked) return\n barked = true\n process.removeListener('SIGHUP', bark)\n setTimeout(() => {\n try {\n process.kill(pid, 'SIGKILL')\n setTimeout(() => process.exit(), 200)\n } catch (_) {}\n }, 500)\n })\n process.on('SIGHUP', bark)\n}\n`\n\nexport const watchdog = (child: ChildProcess) => {\n let dogExited = false\n const dog = spawn(\n process.execPath,\n ['-e', watchdogCode, String(child.pid)],\n {\n stdio: 'ignore',\n }\n )\n dog.on('exit', () => (dogExited = true))\n child.on('exit', () => {\n if (!dogExited) dog.kill('SIGTERM')\n })\n return dog\n}\n"]}
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "foreground-child",
|
|
3
|
-
"version": "3.1.1",
|
|
4
|
-
"description": "Run a child as if it's the foreground process. Give it stdio. Exit when it exits.",
|
|
5
|
-
"main": "./dist/cjs/index.js",
|
|
6
|
-
"module": "./dist/mjs/index.js",
|
|
7
|
-
"types": "./dist/mjs/index.d.ts",
|
|
8
|
-
"exports": {
|
|
9
|
-
".": {
|
|
10
|
-
"import": {
|
|
11
|
-
"types": "./dist/mjs/index.d.ts",
|
|
12
|
-
"default": "./dist/mjs/index.js"
|
|
13
|
-
},
|
|
14
|
-
"require": {
|
|
15
|
-
"types": "./dist/cjs/index.d.ts",
|
|
16
|
-
"default": "./dist/cjs/index.js"
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
"files": [
|
|
21
|
-
"dist"
|
|
22
|
-
],
|
|
23
|
-
"engines": {
|
|
24
|
-
"node": ">=14"
|
|
25
|
-
},
|
|
26
|
-
"dependencies": {
|
|
27
|
-
"cross-spawn": "^7.0.0",
|
|
28
|
-
"signal-exit": "^4.0.1"
|
|
29
|
-
},
|
|
30
|
-
"scripts": {
|
|
31
|
-
"preversion": "npm test",
|
|
32
|
-
"postversion": "npm publish",
|
|
33
|
-
"prepublishOnly": "git push origin --follow-tags",
|
|
34
|
-
"prepare": "tsc -p tsconfig.json && tsc -p tsconfig-esm.json && bash ./scripts/fixup.sh",
|
|
35
|
-
"pretest": "npm run prepare",
|
|
36
|
-
"presnap": "npm run prepare",
|
|
37
|
-
"test": "c8 tap",
|
|
38
|
-
"snap": "c8 tap",
|
|
39
|
-
"format": "prettier --write . --loglevel warn",
|
|
40
|
-
"typedoc": "typedoc --tsconfig tsconfig-esm.json ./src/*.ts"
|
|
41
|
-
},
|
|
42
|
-
"prettier": {
|
|
43
|
-
"semi": false,
|
|
44
|
-
"printWidth": 75,
|
|
45
|
-
"tabWidth": 2,
|
|
46
|
-
"useTabs": false,
|
|
47
|
-
"singleQuote": true,
|
|
48
|
-
"jsxSingleQuote": false,
|
|
49
|
-
"bracketSameLine": true,
|
|
50
|
-
"arrowParens": "avoid",
|
|
51
|
-
"endOfLine": "lf"
|
|
52
|
-
},
|
|
53
|
-
"tap": {
|
|
54
|
-
"coverage": false,
|
|
55
|
-
"jobs": 1,
|
|
56
|
-
"node-arg": [
|
|
57
|
-
"--no-warnings",
|
|
58
|
-
"--loader",
|
|
59
|
-
"ts-node/esm"
|
|
60
|
-
],
|
|
61
|
-
"ts": false
|
|
62
|
-
},
|
|
63
|
-
"repository": {
|
|
64
|
-
"type": "git",
|
|
65
|
-
"url": "git+https://github.com/tapjs/foreground-child.git"
|
|
66
|
-
},
|
|
67
|
-
"author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)",
|
|
68
|
-
"license": "ISC",
|
|
69
|
-
"devDependencies": {
|
|
70
|
-
"@types/cross-spawn": "^6.0.2",
|
|
71
|
-
"@types/node": "^18.15.11",
|
|
72
|
-
"@types/tap": "^15.0.8",
|
|
73
|
-
"c8": "^7.13.0",
|
|
74
|
-
"prettier": "^2.8.6",
|
|
75
|
-
"tap": "^16.3.4",
|
|
76
|
-
"ts-node": "^10.9.1",
|
|
77
|
-
"typedoc": "^0.24.2",
|
|
78
|
-
"typescript": "^5.0.2"
|
|
79
|
-
},
|
|
80
|
-
"funding": {
|
|
81
|
-
"url": "https://github.com/sponsors/isaacs"
|
|
82
|
-
}
|
|
83
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
The ISC License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2009-2023 Isaac Z. Schlueter and Contributors
|
|
4
|
-
|
|
5
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
-
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
-
copyright notice and this permission notice appear in all copies.
|
|
8
|
-
|
|
9
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
10
|
-
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
11
|
-
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
12
|
-
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
13
|
-
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
14
|
-
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
|
|
15
|
-
IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|