Today when I was working with Git I got something wrong and I really cannot understand it. Our team has a private github repo and I pulled some changes from that shared repo. After I did the pull, I can see every changes and the details in git log and everything is all correct. Problem is if you open the file, the changes are not there. I trust git, I'm thinking myself or my teammate did something wrong but for right now I really have no idea how this could happen. If you have any similar experience, suggestions, guess of the reason or deductions, please leave a comment. Thank you guys.
Asked
Active
Viewed 80 times
2
-
6Are you in the correct branch? Are you sure the changes are not there? Have you run a diff between the file you are looking at and the file in the repository? Do you have a clean git status? Have you tried checking out to a different branch and seeing if the changes appear? There are a lot of things you can do to try and narrow the problem down. – Abizern Jul 03 '13 at 07:40
-
probably the best thing to debug this is to use a graphical user interface (gitk, gitx, gitg, ...) and configure it to show all branches. if you can find the lost commits there, the next step is to figure out how to get you where the commits are (or get the commits to where you are). – mnagel Jul 03 '13 at 14:02
-
@mnagel: Thanks. I was using SmartGit. My workspace crashed. – Edmond Jul 04 '13 at 07:06