remote ↔ to link local Git Repo to remote Git Repo
aka remote
git remote
to print list of all remote connected Git Repo
git remote add origin _URL
to add remote Git Repo w name of origin at _URL
git remote -v
to print remote Git Repo name & URL
git remote show
to print details for remote Git Repo incl Branch
origin
(default) name for remote Repo
git remote add upstream _URL
to sync local Repo w Upstream Github Repo
References
git remote add origin _URL↔ to addremoteGit Repo w name oforiginat_URLgit pull origin master↔ to downloadremoteGit Repo namedorigin&mergewith local repo namedmastergit clone _URL newName↔ tocloneremoteRepo (at_URL) to local machine & rename tonewNameGithub Repo↔remoteRepo host on github.com--force↔ flag to overwrite Commit History onremoteRepogit remote -v↔ to printremoteGit Repo name & URLgit push --force origin __branch↔ topushlocal Commit toremoteRepo & FORCE sync to local (discardremotehistory) 🔥 bad for teamwork!git push -u origin master↔ topushlocal Git Repo Branch at Master toremoteRepogit push --force-with-lease origin __branch↔ to push local Commit to remote Repo & SAFELY sync (avoid overwrite remote history) ✅ often mandatory to not get fired!