Welcome to the CSC Q&A, on our server named in honor of Ada Lovelace. Write great code! Get help and give help!
It is our choices... that show what we truly are, far more than our abilities.

Categories

+21 votes

While trying to merge I noticed that there was a java class that had a dropdown arrow and when I clicked it there were 2 java classes with that name and it looks to me that both of those files are the exact same. Why does that happen?

asked in CSC305 Fall 2023 by (1 point)

2 Answers

+6 votes

Hmm... I don't know what you're saying about a "dropdown"... you must not be using the terminal for git, but here's one theory:

It sounds like maybe someone renamed a file or folder, possibly just the same name but different upper/lower case letters.

Note: File names in git are case sensitive, even though Windows/Mac file systems are (partially) case insensitive. (Linux uses case sensitive file names.)

answered by (3.4k points)
–3 votes

If you're in the process of merging branches, it's possible that the same class was modified independently in both branches. This can result in the version control system creating two versions of the file if it cannot automatically resolve the differences.

You may want to revisit earlier labs on how to manually resolve merge conflicts.

answered by (1 point)
...