Pavel⇢ has tought me this:
Part I — setup SSH key ¶
- login at
github.com - generate an SSH key. Paste
ssh-keygen -t ed25519 -C "your_email@example.com"to Terminal, replace email (github tutorial). - Add the new key to ssh config (~/.ssh/config):
Host *`
AddKeysToAgent yes`
IdentityFile ~/.ssh/gardenKey`
- enter
cat ~/.ssh/gardenKey.pubto print insides of the .pub file (public part of the key) - copy contents to
github.com/settings/ssh/newand add
Part II — setting local repo ¶
- clone repo using SSH at
github.com(code dropdown) - type in
cdto go to home dir - type in
git clone+ space + copied SSH address - type in:
sergei@Sergeis-MacBook-Pro garden % git config --global user.name "Sergei Kalabin" - type in:
sergei@Sergeis-MacBook-Pro garden % git config --global user.email "deltakatachre@gmail.com"