Last active
January 13, 2016 01:48
-
-
Save darrenrogan/9f50dcba1ef8b8cd69c7 to your computer and use it in GitHub Desktop.
This is a simple script that adds a github user to the ssh key authorized keys
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Usage: add_gh_key <github username> | |
# Credit - https://github.com/darrenrogan | |
function add_gh_key() { | |
NAME=$1 && KEY="$(curl -s https://github.com/$NAME.keys)" && echo "$KEY" $NAME >> ~/.ssh/authorized_keys | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment