MCPcopy
hub / github.com/meteor/meteor / onConnect

Method onConnect

tools/shell-client.ts:127–145  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

125 process.stdin.resume();
126
127 const onConnect = () => {
128 this.firstTimeConnecting = false;
129 this.reconnectCount = 0;
130 this.connected = true;
131
132 // Sending a JSON-stringified options object (even just an empty
133 // object) over the socket is required to start the REPL session.
134 sock.write(JSON.stringify({
135 columns: process.stdout.columns,
136 terminal: !isEmacs(),
137 key: key
138 }) + "\n");
139
140 process.stderr.write(shellBanner());
141 process.stdin.pipe(sock);
142 if (process.stdin.setRawMode) { // https://github.com/joyent/node/issues/8204
143 process.stdin.setRawMode(true);
144 }
145 }
146
147 const onClose = () => {
148 tearDown();

Callers

nothing calls this directly

Calls 3

isEmacsFunction · 0.90
shellBannerFunction · 0.85
writeMethod · 0.45

Tested by

no test coverage detected