Tuesday, 25 January 2022

GitHub

Error:Key already in use

When I try to add a ssh public key to my GitHub account, I got that error. To figure out which account has that key

ssh -T -ai ~/.ssh/id_rsa git@github.com

Output: Hi liysysy! You've successfully authenticated, but GitHub does not provide shell access.

to solve it, remove from other account and add to this account

Ask user name when push codes

If you have upload a ssh public key and it still asks for user name when push codes, it is mostly that you are using https://.. as origin. You need to use ssh origin such as git@github.com:rllslslls

To change origin

git remote set-url origin git@github.com:rdgdfghh.git

Create a PR

git push -u origin feature/KLMP-4071

No comments:

Post a Comment