OS X clipboard access from the shell

Chris Siebenmann motivated me to finally do something about the situation of my web site passwords. So I needed some nice password generation process. I looked at 1password but didn’t find it terribly attractive. Instead I’m using the OSX keychain. For generating passwords I use the excellent apg. And since today this shell function: clippass() { apg -M SNCL -m 15 -n 1 | pbcopy pbpaste } This creates a long and safe password, pastes it to the clipboard using pbcopy and then shows it on the command line by pasting it again from the clipboard using pbpaste. ...

February 20, 2009 · Patrice Neff