DEV Community

Livecodebase
Livecodebase

Posted on

How to setup git ssh

Enter ls -al ~/.ssh to see if existing SSH keys are present.

Paste the text below, substituting in your GitHub email address.

ssh-keygen -t ed25519 -C "your_email@example.com"
Enter fullscreen mode Exit fullscreen mode

Start SSH agent in background

eval "$(ssh-agent -s)"
Enter fullscreen mode Exit fullscreen mode

add key to ssh agent

ssh-add ~/.ssh/id_ed25519
Enter fullscreen mode Exit fullscreen mode

Display added SSH Key

cat ~/.ssh/id_ed25519.pub
Enter fullscreen mode Exit fullscreen mode

Top comments (0)