Gitexit code > 0
error: checkout: updating paths is incompatible
$error: checkout: updating paths is incompatible with switching branches.
Did you intend to checkout 'feature/branch' which can not be resolved as commit?
Analysis
You tried to switch branches while also specifying a file path, or the branch name you provided is invalid/ambiguous.
Common Triggers
- ●Running
git checkout <branch> <file>(invalid syntax). - ●Typo in branch name, so Git thinks it's a file path.
Debug Checks
- $Verify the branch name exists.
Resolution
1
Switch branch only:
git checkout <branch>.2
Checkout file from branch:
git checkout <branch> -- <file>.Metadata
- Tool
- Git
- Severity
- High
- Tags
- #git#checkout#syntax