git get remote branch

C++
git remote show origingit branch -rgit fetch origin

git checkout --track origin/<branch_name>git checkout -b test origin/test

// making a local copy of the branch called "test" from origin.git checkout --track origin/<branchname>git fetch
git checkout test

Source

Also in C++: