diff --git a/debugger/util/argument_parser.js b/debugger/util/argument_parser.js index af7bf30..10ca91b 100644 --- a/debugger/util/argument_parser.js +++ b/debugger/util/argument_parser.js @@ -10,6 +10,12 @@ const { ArrayPrototypeJoin, } = primordials; +const { + exitCodes: { + kGenericUserError, + }, +} = internalBinding('errors'); + function parseBoolean(value) { return value === 'true' || value === '1' || value === 'yes'; } @@ -75,6 +81,9 @@ function parseArguments(argv) { return {...options, ...legacyArguments}; } +// the legacy `node inspect` options assumed the first argument was the target +// to avoid breaking existing scripts, we maintain this behavior + function processLegacyArgs(args) { const target = ArrayPrototypeShift(args); let host = '127.0.0.1';