title: Deleting all commits in a branch after certain commit
body: <p>I'm having a difficult time grasping how I can use rebase/revert to accomplish this.</p>
  
  <p>I was working on my <code>master</code> branch and after a certain commit my software stopped working. I did not want to loose the changes made at the time and I was pressured on time to reach a milestone so I went back a few commits with <code>git checkout</code> and created a new branch called <code>working</code> and started pushing all my changes there. Later on I realized that these changes (made on the <code>master</code> branch) were not needed. Now I want to go back to my master branch and delete all the commits after the commit I used to create my <code>working</code> branch and then merge my <code>working</code> branch to <code>master</code> branch.</p>
  
  <p>I've created an image with an online photo editor to try and explain what I'm trying to do. I hope it helps: </p>
  
  <p><img src="https://i.stack.imgur.com/wUhM9.png" alt="screen shot of bitbucket"></p>
  
  <p>I want to keep everything after 5cb967f. get rid of everything between 5cb967f and a0c1de2 (not including those)</p>