git remotes
Simple commands needed for working with multiple remotes in git.
List of remotes
git remote -vAdd a remote
git remote add remoteName http://urlRename a remote
git remote rename oldname newnameCheckout a remote branch
git checkout -b branchname remotename/branchnameDelete a remote
git remote rm remotenameSet a new location for a remote
git remote set-url remoteName url
// Better yet use ssh style
git remote set-url origin git@github.com:user/repo.gitFetch or pull all remotes use --all
Set the upstream tracking for a branch
On first push use -u
-or-
git fetch --all //This is done to make sure you have the new remotes locally.
git branch --set-upstream-to remotename/branchnameDelete branches on a remote (just precede the branchname with a :)
git push remotename :branchname