Git
Connect a local project to an existing GitHub repo with SSH
The straight path for connecting a local project to an already created GitHub repository over SSH.
Use this when the GitHub repo already exists and the local project needs to connect to it with SSH.
Check current remotes #
git remote -vAdd the existing GitHub repo as origin #
git remote add origin git@github.com:YOUR-USERNAME/personal-hugo-docs.gitRename branch to main #
git branch -M mainFirst push upstream #
git push -u origin main