Reputation: 41
I have deleted a set of files from my local development machine, however they are not deleted on GitHub and are thus showing on my production machine again when I deploy.
How can I force these files to be deleted in the next commit?
Upvotes: 1
Views: 227
Reputation: 2886
The easiest thing is to use git add -u
It'll remove files that has been manually deleted from your git files.
Just commit
and push
normally after that.
Check out the git cheat sheets for others git commands.
And also check that thread: git rm multiple files that have already been deleted from disk
Upvotes: 1
Reputation: 538
You can use git rm file or git rm -f file if you have already delete the file you have to commit after that
see : http://www.kernel.org/pub/software/scm/git/docs/git-rm.html for more detail on git rm
Upvotes: 0