This message can also happen if git-lfs
is used and a file pointer was overwritten by a real file.
then you use:
git stash
git lfs migrate import
git pull
full output from my case
? git stash
Saved working directory and index state WIP on master: 5d4ad47 Merge branch 'feature/...' into 'master'
Encountered 1 file(s) that should have been pointers, but weren't:
public/apple-touch-icon.png
? git pull
Updating 5a4ad44..b25f79d
error: Your local changes to the following files would be overwritten by merge:
public/apple-touch-icon.png
Please commit your changes or stash them before you merge.
Aborting
? git lfs migrate import
migrate: Fetching remote refs: ..., done
migrate: Sorting commits: ..., done
migrate: Rewriting commits: 100% (0/0), done
migrate: Updating refs: ..., done
migrate: checkout: ..., done
? git pull
Updating 5d4ad47..a25c79a
Fast-forward
public/apple-touch-icon.png | Bin 2092 -> 130 bytes
public/favicon.ico | Bin 6518 -> 1150 bytes
2 files changed, 0 insertions(+), 0 deletions(-)