git - How to merge my uncommitted files with the changes from the repository, within the same branch? -


i have 1 file, say, index.html.

i change line 1000-1200 on file. coworker, working on same branch me, commit changes on line 600-800 before had chance commit , push.

when tried push commit, github desktop mac said head on repo greater head, need pull first. when tried pull, github deskop told me changes on index.html overwrite changes.

i use github, 1 week. never happens when used svn tortoisesvn in past. tried merge changes first uncommitted files, , if can't, show me conflicted lines are, , lines should decided taken version. don't have option in github desktop. don't understand how in git console.

so, how that?

you must stash local changes, pull remote changes , unstash local changes onto updated working tree.

any conflicts between changes , remote changes show when git stash pop.

git stash git pull git stash pop 

Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -