In some cases we get this type of problems, i will explain the points in steps wise
- If two persons works on the project personA, personB.
- If personB adds new files, those files path saves in our project binary file. so personsB done Commit and pushed the code.
- and personA also added new files, here also same way files path saves in our project binary file and performed commit operation and pulled the code which on remote side.
- Here the situation arise when personA pulls the code conflicts arise in the binary file. in this case project disappears from the Project Explorer.
i faced this type of problem before. i merged both files not worked.
Solution for the above problem
Whenever if we perform pull operation and get conflicts in binary file. I follow the below procedure
In this case i use this commandgit checkout --ours binaryfilenamewithpath
git checkout --ours filename -> it keeps your local file without adding others changes
by this we can avoid project disappeared from the Project Explorer cases. Here you get personBs files but files links can not add to the binary file.
so manually we have to those files into our project for linking purpose.
then you can commit the your project.
I prefer this way to resolve this type of problems. If you have any doubts please ask me.
Solution for your problem
- Execute
git log command it will show your previous commits information with their ids git reset --hard commitid(c14809fa) it will make your local code and local history be just like it was at that commit. - pull your code using
git pull origin branchname - if you get conflict in binaryfile, then your project disappear from eclipse workspace. use this command
git checkout --ours binaryfilewithpath to avoid that. - if you want to add files to your project and resolve conflicts in other files.
- then commit your code by using
git commit -a -m 'your commit message'