Forcing a re-sync with a remote repository

Having done a git rebase on my local repo, and then done a forced update on the remote repo, I needed to copy the remote repo to my live website. I achieved this, after reading this thread on Stack Exchange.

git fetch --all
git reset --hard origin/master

Now my history on the website matches the history on the remote master.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>