MATLAB: How to checkout a git branch which tracks the remote in MATLAB R2017a

MATLAB

I have cloned a remote git repository and in my local copy I now want to checkout a specific branch which already exists on the remote and I want my locally copy to track this remote. With command line git, if I wanted to checkout branch foo, I would simply use:
git checkout foo
And this would then automatically track the remote without further configuration needed.

Best Answer

To check-out a specific branch in MATLAB
1. Go to "Source Control" -> "Branches"
2. Under "Branch and Tag Creation", manually enter:
Source: origin/foo
Name: foo
Hit "Create".
3. Select the "foo" branch in the Branch Browser and click "Switch".