“Cannot update paths and switch to branch at the same time”

I sometimes use the checkout -b option to create a new branch, check it out at the same time and set up tracking in one command.

In a new environment, I get this error:

$ git checkout -b test --track origin/master
fatal: Cannot update paths and switch to branch 'test' at the same time.
Did you intend to checkout 'origin/master' which can not be resolved as commit?

Why does Git not like it? This used to work with the same repo.

13 Answers
13

Leave a Comment