ssh-keygen -t rsa -b 4096 (After running commang jsut press enter continously to get they keys)
cat ~/.ssh/id_rsa.pub (To get public key run this command on terminal - |id_rsa.pub| is the filename in folder)
cat ~/.ssh/id_rsa (To get private key run this command)
##To add that in github account:
- Got to you profile setting
- Click on (SSH and GPG Keys)
- Click add new
- Paste key and click save
ssh -T [email protected]
Thsi will show output like (You've successfully authenticated, but GitHub does not provide shell access.)
###Trouble shouting If above key give some error mesaging then use the belwo steps. Make sure to switch terminal to git bash in vs-code; #Run command
eval ssh-agent -s
ssh-add ~/.ssh/id_rsa
ssh -T [email protected]