- What I'm trying to do:
I work with two friends on a university project, they made some changes to the code. I've also made a lot of changes to the code, most of which I want to keep.
I'm new to git and don't know where to start. My friend suggested I use:
git pull origin
When I do that I get:
error: Your local changes to the following files would be overwritten by merge:
Please, commit your changes or stash them before you can merge
I read somewhere on stackoverflow: How do you git fetch then merge? "Error: Your local changes to the following files would be overwritten by merge"
That if I don't commit changes to local repository, they'll be lost?
- How do you commit locally?
- How do I merge changes(Is there a way I could use beyond compare please)?
- How do I upload the changes?
Thanks
This is what it looks like now:
Arthur Wulf@SUPERWOLF-PC /c/Current Project/study-wise (master|MERGING)
$ git pull origin master
M .pydevproject
U src/app.yaml
M src/getters/__init__.pyc
M src/index.yaml
M src/model/ClassM.pyc
M src/model/CourseM.py
M src/model/CourseM.pyc
M src/model/GeneralM.pyc
M src/model/LectureM.py
M src/model/LectureM.pyc
M src/model/PostClassM.py
A src/model/PostClassM.pyc
M src/model/QuestionM.py
M src/model/QuestionM.pyc
M src/model/StudentM.py
M src/model/StudentM.pyc
M src/model/TopicM.py
M src/model/TopicM.pyc
M src/model/__init__.pyc
M src/setters/__init__.pyc
A src/setters/setQuestionStats.py
D src/setters/setRemoveOldData.py
A src/setters/setStartNewClass.py
A src/setters/setStudentAnswer.py
D src/setters/setTopicChanged.py
A src/setters/setUpdateTopicStats.py
M src/view/allCourses.html
M src/view/lecture.html
U src/view/prof.html
M src/view/question.html
Pull is not possible because you have unmerged files.
Please, fix them up in the work tree, and then use 'git add/rm <file>'
as appropriate to mark resolution, or use 'git commit -a'.
What I do not understand is how do I beyond compare the files on my local side with the ones on the online origin repository side and merge them?