diff --git a/src/node/nodeDebug.ts b/src/node/nodeDebug.ts index bb93f677..d18abc65 100644 --- a/src/node/nodeDebug.ts +++ b/src/node/nodeDebug.ts @@ -286,6 +286,9 @@ interface LaunchRequestArguments extends DebugProtocol.LaunchRequestArguments, C externalConsole?: boolean; /** Where to launch the debug target. */ console?: ConsoleType; + + /** internal */ + __restart?; boolean; } /** @@ -808,6 +811,11 @@ export class NodeDebugSession extends LoggingDebugSession { return; } + if (typeof args.__restart === 'boolean' && args.__restart && typeof args.port === 'number') { + this._attach(response, args.port, undefined, args.timeout); + return; + } + this._noDebug = (typeof args.noDebug === 'boolean') && args.noDebug; if (typeof args.console === 'string') {