Notes

Git - Switch remote URL from HTTPS to SSH

author: Paul Kim

categories: git

tags: git

Switch remote URL from HTTPS to SSH

# show remote name and urls
git remote -v
# remove a remote named 'origin'
git remote remove origin
# add a remote named 'origin'
git remote add origin git@github.com:git-user/git-repo.git

Switch remote URL from SSH to HTTPS

# show remote name and urls
git remote -v
# remove a remote named 'origin'
git remote remove origin
# add a remote named 'origin'
git remote add origin https://github.com/git-user/git-repo.git
Source

Git push results in “Authentication Failed”


ChromeEdgeFirefoxOpera

© 2021 paulkode.com. All rights reserved.