title: Get rid of branch and bad code with Git
body: <p>I'm working on a new branch. Basically I've messed my code up and would like to go back to master and start fresh from a new branch.</p>
  
  <p>Would <code>$ git revert</code> get me back to the master? </p>
  
  <p>or should I be doing the following:</p>
  
  <pre><code>$ git branch -D branch-name
  </code></pre>
  
  <p>I want to get rid all the code and current entire branch that is checked out.</p>
  
  <p>The online documentation is a bit confusing - scared to mess everything up.</p>