Checkout (switch)
See the :term:Checkout
glossary page for more information.
How to check out a ref or commit
To check out a ref (e.g. branch, or tag) or commit:
git switch <ref|commit>
Note
In git <v2.23 (not recommended):
git checkout <ref|commit>