Skip to content

Instantly share code, notes, and snippets.

@sanusart
Created March 15, 2015 21:24
Show Gist options
  • Save sanusart/1ea582662d320e0db82d to your computer and use it in GitHub Desktop.
Save sanusart/1ea582662d320e0db82d to your computer and use it in GitHub Desktop.
git remove file/dir from history #git
git filter-branch --force --prune-empty --index-filter 'git rm -rf --cached --ignore-unmatch DIR-OR-FILE' --tag-name-filter cat -- --all
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment