Copying my ssh key to my clipboard is always something I have to google. It’s different depending on operating system and depends on what you have installed. This is a short guide on how to copy your ssh key to the clipboard.
Mac
- Type: pbcopy < ~/.ssh/id_rsa.pub
Linux (Ubuntu)
- Type and copy output: cat ~/.ssh/id_rsa.pub
Windows (Git Bash)
- Type: clip < ~/.ssh/id_rsa.pub
Please leave a comment below if you have a better way or would like me to add an additional operating system.
Thanks for reading. Make sure you follow me on Twitter to stay up to date on the progress of my side projects T.LY, Weather Extension, and Link Shortener Extension. If you are interested in the tech I use daily, check out my uses page.
What is it for FreeBSD?
Should be the same as Ubuntu 👍
And if I want to copy a key from a remote host and to store it in a file in Windows? What file format it should be? I mean code page and other. For example to use in Secure Shell App for Chrome.
What operating system are you remoting into?
I have VPS on CentOS and another one on FreeBSD. Copying from CentOS was with little problems, but OK. But I tried to copy from FreeBSD for 100500 times, with no luck.