Answers for "github remove local commits"

8

git remove all local commits

git reset --hard origin/<branch_name>
Posted by: Guest on April-18-2021
2

remove commits from github

git clone 'VerybadRepo.git'
cd VeryBadRepo.git
git log
(find and copy "commit id"  )
git rebase -i "commit id"
remove line with unwanted commits ; save and close editor
git  push -f origin master/main
Posted by: Guest on October-04-2021

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language