error: Your local changes to the following files would be overwritten by merge

The following error occurred when using git pull command today

The result is the above error prompt, translated by Youdao dictionary software, the content is (error: your local changes to the following files will be merged and covered)

Using git log — oneline to check the log, you didn’t get the code. You checked a lot of information and other big men’s blogs on the Internet

The following git instruction method is used   It means to abandon local modification and directly override

1 git reset --hard
2 git pull


Read More: