Skip to content

Latest commit

 

History

History
81 lines (58 loc) · 1.14 KB

File metadata and controls

81 lines (58 loc) · 1.14 KB

GitHub SSH Keys

List existing public Keys

# List all files in the .ssh directory
ls -l ~/.ssh

# Any existing public keys are stored in the files
id_rsa.pub
id_ecdsa.pub
id_ed25519.pub

Generate ED25519 Key

Local Computer

# Generate a new SSH key
ssh-keygen -t ed25519 -C "gb@embed-dsp.com"
# Start the ssh-agent in the background.
eval "$(ssh-agent -s)"
# Add SSH key to the ssh-agent
ssh-add ~/.ssh/id_ed25519

GitHub

# Add your SSH key to GitHub
https://github.com/settings/keys

New SSH key
  Title: kenny: gb@embed-dsp.com
  Key:   <paste in the content of ~/.ssh/id_ed25519.pub>

Generate RSA Key

Local Computer

# Generate a new SSH key
ssh-keygen -t rsa -C "gb@embed-dsp.com"
# Start the ssh-agent in the background.
eval "$(ssh-agent -s)"
# Add SSH key to the ssh-agent
ssh-add ~/.ssh/id_rsa

GitHub

# Add your SSH key to GitHub
https://github.com/settings/keys

New SSH key
  Title: kenny: gb@embed-dsp.com
  Key:   <paste in the content of ~/.ssh/id_rsa.pub>

Test SSH connection with GitHub

ssh -T git@github.com