git pull - reporting that I modified files, but I did not

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When I do a git pull, I am getting a messages that changes to local
files would be overwritten by a merge, but  I have not changed these
files locally at all, I have not opened them in my IDE.
This happens every now and then.

1) Why does this happen?

2) How do I prevent this from happening in the future?

3) How do I get out of this state so that I can do a git pull and
rebuild my code?

---
In other instances, when I do a git pull (not getting the message
above,  I will see something like:
M      src/MyClass.java      <= a file that I did not touch or modify
D       src/AnotherClass.java   <= a file that I did not delete or touch
M     src/MyModifiedClass.java   <= a file that I indeed modified for
which in the pull there are no merge conflicts.

and the pull is successful, (then I want to push my changes), but I
did not change either of the above two files

If I see the above, am I OK to push?  My thinking is that git thinks I
changed 'src/MyClass.java' and if I do a diff there are differences,
but I do not want to push because I NEVER TOUCHED THAT FILE IN ANY
WAY.

What is going on here?  Maybe this is normal and I simply do not
understand correctly.

What is happening?  I would expect to see only line items 'M' and 'D'
for files that I personally have modified and deleted.
If I push at this point, will I overwrite changes in the repo pushed
by others and muck things up?

thanks


J.V.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]