Loading...
git checkout -b fix/footer
git checkout a1b2c3dgit switch -c fix/footer
git switch --detach a1b2c3dswitch handles branches only, and inspecting a commit requires an explicit --detach.
git switch to accept a commit hash without --detach.git switch <branch>, and new branches use git switch -c <branch>.git restore, not git switch or git checkout -- <file>.git switch --detach <commit>.Run git switch -. It switches to the branch you were on before.
Your uncommitted changes would be overwritten by the other branch. Commit or stash them first.