Created
February 23, 2018 18:27
-
-
Save aks/b649da7b11df0c9a93cc4ec664563279 to your computer and use it in GitHub Desktop.
Permanently remove files from a repo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # wanted to remove "doc" directory and all of it's contents | |
| git filter-branch -f --index-filter 'git rm --cached --ignore-unmatch -r -f doc' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment