In committing and pushing to my repo, I get the following error:
The issue is that I've already manually deleted the video file. The video does not exist anywhere in my repo.
I also tried to
git rm src/assets/video/Greensleeves
and it says fatal: pathspec src/assets/video/Greensleeves did not match any files
.
How can I get passed this so that I can commit/push?
Try and apply the new
git filter-repo
, which does replace the oldgit filter-branch
or BFG.It has many usage examples, including path-based filtering, in order for you to remote the
src/assets/video/Greensleeves
file in past commits:Then
git push --force
(that does rewrite the history of your repository, so make sure to notify any other collaborator)Since it must be done on a fresh clone:
That is, for point 3: