Skip to content

Commit 794d1fe

Browse files
committed
Get server URL from the client preferences (vscode-trace-extension)
This allows to change the URL when running the vscode-trace-server extension in conjunction with the vscode-trace-extension. fixes #6 Signed-off-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
1 parent 6fff008 commit 794d1fe

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/trace-server.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import * as vscode from 'vscode';
66
// Based on github.com/eclipse-cdt-cloud/vscode-trace-extension/blob/master/vscode-trace-extension/package.json
77
// -for naming consistency purposes across sibling extensions/settings:
88
const section = 'trace-server.traceserver';
9+
const clientSection = 'trace-compass.traceserver';
910

1011
const key = 'pid';
1112
const millis = 10000;
@@ -128,8 +129,12 @@ export class TraceServer {
128129
return vscode.workspace.getConfiguration(section);
129130
}
130131

132+
private getClientSettings() {
133+
return vscode.workspace.getConfiguration(clientSection);
134+
}
135+
131136
private getServerUrl() {
132-
const from = this.getSettings();
137+
const from = this.getClientSettings();
133138
return this.getUrl(from) + '/' + this.getApiPath(from);
134139
}
135140

0 commit comments

Comments
 (0)