Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

github checkout

# Open/checkout a previous branch
git checkout <existing-branch>

# Open/checkout a previous commit
git checkout <commit> [when commit is not a branch name

# Create a new branch from current branch
git checkout -b <new-branch>

# Create a new branch from existing-branch
git checkout -b <new-branch> <existing-branch>

# Go/Checkout to last commit or branch reset
git checkout .
 
PREVIOUS NEXT
Tagged: #github #checkout
ADD COMMENT
Topic
Name
8+2 =