Alex Rivera | Logout

Remove references of physically removed files from remote Git repository

Asked 2011-03-28T11:41:54.553
9

I have deleted a lot of files from my Git repository (from many different directories) physically.

I can still see their reference and if I make a commit to GitHub, old files are still there.

I need to remove those references from the remote repo server (GitHub) and as well as from my local PC.

How can I remove these references from the repositories?

Edit
Report

1 Answer

4

If you want to remove a file from all commits of the repository, you need git filter-branch. Examples for using it can be found all over the internet, e.g. on GitHub.

answered 2011-03-28T11:46:48.440

Your Answer