git: How do I get the latest version of my code?

前端 未结 11 1134
野性不改
野性不改 2021-01-29 17:08

I\'m using Git 1.7.4.1. I want to get the latest version of my code from the repository, but I\'m getting errors ...

$ git pull
….
M   selenium/ant/build.proper         


        
11条回答
  •  孤城傲影
    2021-01-29 17:42

    If you are using Git GUI, first fetch then merge.

    Fetch via Remote menu >> Fetch >> Origin. Merge via Merge menu >> Merge Local.

    The following dialog appears.

    Select the tracking branch radio button (also by default selected), leave the yellow box empty and press merge and this should update the files.

    I had already reverted some local changes before doing these steps since I wanted to discard those anyways so I don't have to eliminate via merge later.

提交回复
热议问题