title: Undo git rm -r --cached
body: <p>My <code>.gitignore</code> file wasn't working, so I followed this <a href="https://stackoverflow.com/questions/11451535/gitignore-not-working">question</a>.</p>
  
  <p>And now I have bunch of files that I need to commit, in order to proceed.
  I made a mistake and committed those, because I couldn't find a way to get rid of those. </p>
  
  <p>Is there any way that I can revert all these actions? I can't do <code>reset</code> cause I now I get error:
  <code>error: The following untracked working tree files would be overwritten by checkout</code>.</p>
  
  <p>Stupid stupid mistake, and I can find solution for this.</p>