开发者

How do I do git pull so that it will update the files in the working

When I do git pull origin master, 开发者_开发技巧it does not seem to update the files in the folder of the git repository.


A few suggestions,

Try a git pull -v origin master to see if the verbose version produces any clue.

If you can clone your repo and get it in a state before any git pull:

  • Check if the git pull you just did introduced any changes:
    current=`git rev-parse HEAD`
    git pull origin
    git diff $current..
  • try a git fetch origin master, which is equivalent to "git fetch origin master:", not to "git fetch origin master:master" (i.e.: it stores fetched value of 'master' branch (of remote 'origin') in FETCH_HEAD, and not in 'master' branch or remote-tracking 'remotes/origin/master' branch.
    That means you can try and detect if any changes are to be introduced by that fetch:
     git diff ...FETCH_HEAD


You can haz gremlinz.

git-pull is supposed to fetch the remote changes and merge them into the current branch.

To verify that the changes have been merged, do git log to verify that the revisions that you are expecting are in your local branch.

From git-pull doco:

Merge into the current branch the remote branch next:

$ git pull origin next


Maybe you didn't make any change to the remote (or who ever maintains it didn't update it).

Maybe you have more than one remote and you're confused about which one pull is supposed to fetch form.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜