How do I fetch upstream repo and make it replace master? I only have one branch on my repo, which is master, and I completely messed it up, so I basically need to start over fro
git reset # you need to know the last good hash, so you can remove all your local commits
git fetch upstream
git checkout master
git merge upstream/master
git push origin master -f