title: Git remove large file - file not found
body: <p>I am trying to push my <code>.git</code> to Github. </p>
  
  <pre><code>git push origin master
  [...]
  remote: error: GH001: Large files detected. You may want to try Git Large File Storage - https://git-lfs.github.com.
  remote: error: Trace: fc1cc7aed3765ca1e847dee4b7fc831f
  remote: error: See http://git.io/iEPt8g for more information.
  remote: error: File .terraform/plugins/darwin_amd64/terraform-provider-aws_v1.41.0_x4 is 107.37 MB; this exceeds GitHub's file size limit of 100.00 MB
  To [example].git
   ! [remote rejected] master -&gt; master (pre-receive hook declined)
  error: failed to push some refs to 'git@[example.git].git'
  </code></pre>
  
  <p>Which tells me that </p>
  
  <pre><code>.terraform/plugins/darwin_amd64/terraform-provider-aws_v1.41.0_x4 
  </code></pre>
  
  <p>Is too big. <br/></p>
  
  <p>Fair enough: </p>
  
  <pre><code>rm -rf .terraform/
  git rm -rf .terraform/
  git rm -rf --cached .terraform/
  </code></pre>
  
  <p>Which gives </p>
  
  <pre><code>git status
  On branch master
  Changes to be committed:
    (use "git reset HEAD &lt;file&gt;..." to unstage)
  
      deleted:    .terraform/plugins/darwin_amd64/lock.json
      deleted:    .terraform/plugins/darwin_amd64/terraform-provider-aws_v1.41.0_x4
  </code></pre>
  
  <p>So, seems to be okay. </p>
  
  <p>However, when pushing one more time (after commit), I got the exact same issue I have at the very beginning. </p>
  
  <p>Except this time I have no more <code>.terraform</code>, neither in my <code>.git</code> nor in my local folder. </p>
  
  <p>What is causing the issue, and how should I solve it? <br/>
  I suspect there is some git history to be re-written, but not sure about that. Appreciate any help!</p>
  
  <p><strong>EDIT</strong>
  No, the other SO answers did not help with my case. <br/> Please see the answer I gave below. </p>