If you don’t have Git already installed, I recommend installing it through Homebrew. (https://brew.sh/)

The command you need to run is: brew install git

Configuring Git
Before we move forward, adapt the following commands with your name and email.

git config --global user.name “Your full name”
git config — global user.email “you@example.com

ssh-keygen - use this to generate your private/public key pair
ssh-add -K ~/.ssh/id_rsa - use this command to store your passphrase in your macOS keychain.

#git #gitlab

Setup Git for using GitLab (Including SSH Key) - macOS
2.00 GEEK