title: Fixing Git repo after incorrect merging
body: <p>I had a bunch of separate branches, and I wanted to merge them, as each of them was an update to a different part of the program.</p>
  
  <p>I guess I was supposed to merge them but instead I ran a <code>git commit -a</code> after cheking out each branch.</p>
  
  <p>Then I realized the whole program went back in time, so I ran a <code>git reset --soft HEAD</code> (I read in an article somewhere that this should help), but that didn't do anything.</p>
  
  <p>I also got this message from git about manually removing some <code>./git/index.lock</code> so I moved it to <code>./git/backup_of_index.lock</code>, but that didn't seem to do anything, either.</p>
  
  <p>How do I fix my repository and merge all the branches?</p>