MCPcopy Index your code
hub / github.com/codeaashu/claude-code / wrapForMultiplexer

Function wrapForMultiplexer

src/ink/termio/osc.ts:35–44  ·  view source on GitHub ↗
(sequence: string)

Source from the content-addressed store, hash-verified

33 * wrapped \x07 is opaque DCS payload and tmux never sees the bell.
34 */
35export function wrapForMultiplexer(sequence: string): string {
36 if (process.env['TMUX']) {
37 const escaped = sequence.replaceAll('\x1b', '\x1b\x1b')
38 return `\x1bPtmux;${escaped}\x1b\\`
39 }
40 if (process.env['STY']) {
41 return `\x1bP${sequence}\x1b\\`
42 }
43 return sequence
44}
45
46/**
47 * Which path setClipboard() will take, based on env state. Synchronous so

Callers 4

cleanupTerminalModesFunction · 0.85
unmountMethod · 0.85
useTerminalNotificationFunction · 0.85
useTabStatusFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected