I hate re-entering the password when pushing to Github!
Workaround: SSH connection!
1 Create an SSH key in your local terminal
ssh-keygen -t ed25519 -C "firstname.lastname@example.org" ssh-keygen -t ed25519 -C "email@example.com"
You don’t have to type in a password. Just press
2 Start ssh agent, “Use” the generated key (in my case
eval `ssh-agent -s` ssh-add ~/.ssh/id_ed25519.pub
3 Open the key file
4 Copy everything from the file
5 Paste the key to github SSH creator, give it any name
6 Check if you are connected to github. Console:
ssh -T firstname.lastname@example.org
7 Connect to remote repo via SSH
git remote -v
If you’re updating to use HTTPS, your URL might look like:
If you’re updating to use SSH, your URL might look like:
To switch remote URLs from HTTPS to SSH type:
git remote set-url origin email@example.com:USERNAME/REPOSITORY.git git remote set-url origin firstname.lastname@example.org:yshmarov/REPOSITORY.git
When creating a remote, make sure you “clone with SSH” instead of “clone with HTTPS”.
That’s it! Next time you
git push anything, it should authenticate automatically, and you’ll not have to enter your credentials on C9 again.