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

Function readClipboardViaPbpaste

src/utils/computerUse/executor.ts:70–78  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

68}
69
70async function readClipboardViaPbpaste(): Promise<string> {
71 const { stdout, code } = await execFileNoThrow('pbpaste', [], {
72 useCwd: false,
73 })
74 if (code !== 0) {
75 throw new Error(`pbpaste exited with code ${code}`)
76 }
77 return stdout
78}
79
80async function writeClipboardViaPbcopy(text: string): Promise<void> {
81 const { code } = await execFileNoThrow('pbcopy', [], {

Callers 1

typeViaClipboardFunction · 0.85

Calls 1

execFileNoThrowFunction · 0.85

Tested by

no test coverage detected