title: Remove a directory permanently from git
body: <p>In my personal git repo, I have a directory that contains thousands of small images that are no longer needed. Is there a way to delete them from the entire git history? I have tried </p>
  
  <pre><code>git filter-branch --index-filter "git rm -rf --cached --ignore-unmatch imgs" HEAD
  </code></pre>
  
  <p>and</p>
  
  <pre><code>git filter-branch --tree-filter 'rm -fr imgs' HEAD
  </code></pre>
  
  <p>but the size of the git repo remains unchanged. Any ideas?</p>
  
  <p>Thanks</p>