Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

reset one branch onto another

# Make sure your working tree is in a clean state
git status

# Check out the branch you want to change, e.g. some-branch
git checkout some-branch

# Reset that branch to some other branch/commit, e.g. target-branch
git reset --hard target-branch
Source by www.reddit.com #
 
PREVIOUS NEXT
Tagged: #reset #branch
ADD COMMENT
Topic
Name
2+9 =