title: Undo git last commit push
body: <p>I wanted to undo the last changes I made to a file both on my local repo and the repo on Github. (<code>origin</code>)</p>
  
  <p>Could someone please point me to a post/blog of doing it.</p>
  
  <p>Here are the steps I did for committing the changes:</p>
  
  <pre><code>git add -A
  git commit -m "changed header"
  git push origin master
  </code></pre>
  
  <p>How can I undo the last changes, both on my local repo and origin.</p>