Posted By: Anonymous
On my branch I had some files in .gitignore
On a different branch those files are not.
I want to merge the different branch into mine, and I don’t care if those files are no longer ignored or not.
Unfortunately I get this:
The following untracked working tree files would be overwritten by merge
How would I modify my pull command to overwrite those files, without me having to find, move or delete those files myself?
The problem is that you are not tracking the files locally but identical files are tracked remotely so in order to “pull” your system would be forced to overwrite the local files which are not version controlled.
git add * git stash git pull
This will track all files, remove all of your local changes to those files, and then get the files from the server.