First, you need to make an open terminal after this type
mkdir -p ~/.ssh echo public_key_string >> ~/.ssh/authorized_keys chmod -R go= ~/.ssh chown -R shabeer:shabeer ~/.ssh ssh-keygen or ssh-keygen -t ed25519 -C " mail@example.com " xclip -sel clip < ~/.ssh/id_ed25519.pub ~/.ssh/gitlab_rsa.pub
at this time you can see your key and copy it, after that go to the Gitlab settings and select SSH Keys, you will see that there is an option to add this copied key
source share