I am wanting to double check my work with git.
I am trying to use a remote repo server:
I want to only work on MYBRANCH, so I only clone MYBRANCH
/usr/local/git/bin/git clone -b MYBRANCH git@172.27.13.29:/home/PROJECT.git
when I run
git remote -v
I see
origin git@172.27.13.29:/home/PROJECT.git (fetch)
origin git@172.27.13.29:/home/PROJECT.git (push)
I expected to see MYBRANCH and not origin
Can someone explain that?
originis the name of the remote repository, not the name of a branch.For instance, when you go to push changes back, you’ll type
git push origin MYBRANCHwhich says “push the local branchMYBRANCHto the remote repositoryorigin‘s branchMYBRANCH“.If you want to see remote branches, you should use
git branch -rrather thangit remote -v.