Skip to content

Commit

Permalink
debug: support debugServer per configuration
Browse files Browse the repository at this point in the history
fixes #13783
  • Loading branch information
isidorn committed Oct 28, 2016
1 parent 79134b5 commit 3146507
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
4 changes: 4 additions & 0 deletions src/vs/workbench/parts/debug/node/debugAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,10 @@ export class Adapter {
enum: [request],
description: nls.localize('debugRequest', "Request type of configuration. Can be \"launch\" or \"attach\"."),
};
properties.debugServer = {
type: 'number',
description: nls.localize('debugServer', "For debug extension development only: if a port is specified VS Code tries to connect to a debug adapter running in server mode")
};
properties.configurationNames = {
type: 'array',
default: [],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,12 @@ const schema: IJSONSchema = {
'type': 'object',
oneOf: []
}
}
},
// TODO@Isidor remove support for this in December
debugServer: {
type: 'number',
description: nls.localize('app.launch.json.debugServer', "DEPRECATED: please move debugServer inside a configuration.")
},
}
};

Expand Down Expand Up @@ -259,7 +264,7 @@ export class ConfigurationManager implements debug.IConfigurationManager {

result = filtered.length === 1 ? filtered[0] : config.configurations[0];
result = objects.deepClone(result);
if (config && result) {
if (config && result && config.debugServer) {
result.debugServer = config.debugServer;
}
}
Expand Down

0 comments on commit 3146507

Please sign in to comment.