How do I force an overwrite of local files on a Git pull?
The scenario is following:
- A team member is modifying the templates for a website we are working on
- He is adding some images to the images directory (but forgets to add them under
- He is sending later the images by mail to me
- I’m adding the images under the source control and push them to Github together with other changes
- He cannot pull updates from Github because git doesn’t want to overwrite his files.
The errors I’m getting are:
error: Untracked working tree file ‘public/images/icon.gif’ would be overwritten by merge.
How do I force Git to overwrite them? The guy is a designer – usually I resolve all the conflicts by hand so the server has the most recent version that he just needs to update on his computer.