Privacy Policy
Snippets index

  GIT CHECKOUT: fix error "fatal: 'whatever' could be both a local file and a tracking branch"

Example:

$ git checkout whatever
fatal: 'whatever' could be both a local file and a tracking branch.
Please use -- (and optionally --no-guess) to disambiguate

Replace with:

$ git checkout -b whatever origin/whatever
branch 'whatever' set up to track 'origin/whatever'.
Switched to a new branch 'whatever'