Mark Szymanski
Mark Szymanski

Reputation: 58170

Manipulate the Clipboard in C on Mac OS X

How do you copy text to the clipboard in C or with a Command-Line command?

Upvotes: 4

Views: 1269

Answers (1)

WhirlWind
WhirlWind

Reputation: 14110

pbcopy and pbpaste are your friends on the command line:

echo 'send' | pbcopy
pbpaste > receive.txt

Take a look at the Pasteboard Manager Reference and guide for details on doing this in C.

Upvotes: 5

Related Questions