MCPcopy Create free account
hub / github.com/Marus/cortex-debug / setupTerminal

Method setupTerminal

src/frontend/server_console.ts:88–101  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

86 }
87
88 private setupTerminal() {
89 this.ptyOptions.name = GDBServerConsoleInstance.createTermName(this.ptyOptions.name, null);
90 this.ptyTerm = new PtyTerminal(this.ptyOptions);
91 this.ptyTerm.terminal.show();
92 this.ptyTerm.on('close', () => { this.onTerminalClosed(); });
93 this.ptyTerm.on('data', (data) => { this.sendToBackend(data); });
94 if (this.toBackend === null) {
95 magentaWrite('Waiting for gdb server to start...', this.ptyTerm);
96 this.ptyTerm.pause();
97 } else {
98 magentaWrite('Resuming connection to gdb server...\n', this.ptyTerm);
99 this.ptyTerm.resume();
100 }
101 }
102
103 private onTerminalClosed() {
104 this.ptyTerm = null;

Callers 2

createAndShowTerminalMethod · 0.95
onTerminalClosedMethod · 0.95

Calls 6

onTerminalClosedMethod · 0.95
sendToBackendMethod · 0.95
magentaWriteFunction · 0.90
pauseMethod · 0.80
resumeMethod · 0.80
createTermNameMethod · 0.45

Tested by

no test coverage detected