Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

fix: Apply hack to allow to use ctrl-p on terminal #1201

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,16 @@ export class RemoteTerminalWidget extends TerminalWidgetImpl {

this.socket = this.createWebSocket(this.terminalApiEndPoint!);

const sendListener = (data: string) => this.socket.send(data);
const sendListener = (data: string) => {
this.socket.send(data);

// To use ctrl-p on terminal.
// On k8s with docker, ctrl-p ctrl-q is default detach keys and currently there's no way to customize.
// https://github.com/kubernetes/kubectl/issues/1011
if (data === '\u0010') {
this.socket.send('\u0000');
}
};

let onDataDisposeHandler: IDisposable;
this.socket.onopen = () => {
Expand Down