Skip to content

Commit

Permalink
Generate SSH keys if you don't have them.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon Yurek committed Jun 1, 2011
1 parent 9e8edfa commit ee5fd2f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
7 changes: 6 additions & 1 deletion mac
@@ -1,11 +1,16 @@
#!/usr/bin/env bash

echo "Checking for SSH key, generating one if it exists ..."
[[ -f ~/.ssh/id_rsa.pub || -f ~/.ssh/id_dsa.pub ]] || ssh-keygen -t rsa

echo "Copying public key to clipboard. Paste it into your Github account ..."
cat ~/.ssh/id_rsa.pub | pbcopy
[[ -f ~/.ssh/id_dsa.pub ]] && cat ~/.ssh/id_dsa.pub | pbcopy
[[ -f ~/.ssh/id_rsa.pub ]] && cat ~/.ssh/id_rsa.pub | pbcopy
open https://github.com/account/ssh

echo "Installing Homebrew, a great OS X package manager ..."
ruby -e "$(curl -fsSL https://gist.github.com/raw/323731/install_homebrew.rb)"
brew update

echo "Installing git for version control ..."
brew install git
Expand Down
6 changes: 5 additions & 1 deletion ubuntu
@@ -1,7 +1,11 @@
#!/usr/bin/env bash

echo "Checking for SSH key, generating one if it exists ..."
[[ -f ~/.ssh/id_rsa.pub || -f ~/.ssh/id_dsa.pub ]] || ssh-keygen -t rsa

echo "Copying public key to clipboard. Paste it into your Github account ..."
cat ~/.ssh/id_rsa.pub | xclip
[[ -f ~/.ssh/id_dsa.pub ]] && cat ~/.ssh/id_dsa.pub | xclip
[[ -f ~/.ssh/id_rsa.pub ]] && cat ~/.ssh/id_rsa.pub | xclip
open https://github.com/account/ssh

echo "Using apt-get to install OS packages so let's update it first ..."
Expand Down

0 comments on commit ee5fd2f

Please sign in to comment.