{"thread":{"id":"19416","subject":"Re: problems getting uptodate from a remote repository","startedAt":"2009-05-19T16:09:38Z","lastAt":"2009-05-19T17:19:03Z","messageCount":3,"participants":["Aaron Gray","Sverre Rabbelier","Robert Haines"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"114277","messageId":"9719867c0905190909q74e4a6b9r4857fb6f32ff394@mail.gmail.com","threadId":"19416","inReplyTo":"9719867c0905190908n2364da92s88ad646e8667298c@mail.gmail.com","subject":"Re: problems getting uptodate from a remote repository","fromName":"Aaron Gray","fromEmail":"aaronngray.lists@googlemail.com","sentAt":"2009-05-19T16:09:38Z","receivedAt":"2009-05-19T16:09:38Z","isPatch":false,"sender":{"key":"aaronngray.lists@googlemail.com","avatar":null},"body":"I have done a 'git fetch' but the repo is not being updated to latest changes.\n\nI am getting the message :-\n\n    \"Your branch is behind 'origin/master' by 53 commits, and can be\nfast-forwarded.\n\nwhen I do a 'git checkout master'\n\nWhat is going on here and what can I do about it ?\n\nHere's my config :-\n\n$ git config -l\ncore.repositoryformatversion=0\ncore.filemode=true\ncore.bare=false\ncore.logallrefupdates=true\ncore.ignorecase=true\nremote.origin.url=git://git.cybercomms.org/llvm/trunk/.git\nremote.origin.fetch=+refs/heads/*:refs/remotes/origin/*\nbranch.master.remote=origin\nbranch.master.merge=refs/heads/master\n\nMany thanks in advance,\n\nAaron\n"},{"id":"114290","messageId":"ADB06DB0-9198-4AB4-8BE8-6472B943C872@manchester.ac.uk","threadId":"19416","inReplyTo":"9719867c0905190909q74e4a6b9r4857fb6f32ff394@mail.gmail.com","subject":"Re: problems getting uptodate from a remote repository","fromName":"Robert Haines","fromEmail":"rhaines@manchester.ac.uk","sentAt":"2009-05-19T17:03:55Z","receivedAt":"2009-05-19T17:03:55Z","isPatch":false,"sender":{"key":"rhaines@manchester.ac.uk","avatar":null},"body":"Hi Aaron,\n\nOn 19 May 2009, at 17:09, Aaron Gray wrote:\n\n> I have done a 'git fetch' but the repo is not being updated to  \n> latest changes.\n>\n> I am getting the message :-\n>\n>    \"Your branch is behind 'origin/master' by 53 commits, and can be\n> fast-forwarded.\n>\n> when I do a 'git checkout master'\n>\n> What is going on here and what can I do about it ?\n\n\n<snip config>\n\nA fetch just updates your remote tracking branches in your local  \nrepository, it doesn't merge them as well. To update your local master  \nyou would then do (while on branch master):\n\n$ git merge origin/master\n\nThis extra step allows you to create a new branch with origin/master  \nas its start point to check that you're happy with the updates before  \nyou update your local master should you wish to do so.\n\nCheers,\nRob\n"},{"id":"114289","messageId":"fabb9a1e0905191019j73067de9h3ecf3f9dd9ab44e4@mail.gmail.com","threadId":"19416","inReplyTo":"9719867c0905190909q74e4a6b9r4857fb6f32ff394@mail.gmail.com","subject":"Re: problems getting uptodate from a remote repository","fromName":"Sverre Rabbelier","fromEmail":"srabbelier@gmail.com","sentAt":"2009-05-19T17:19:03Z","receivedAt":"2009-05-19T17:19:03Z","isPatch":false,"sender":{"key":"srabbelier@gmail.com","avatar":"https://avatars.githubusercontent.com/u/3098?v=4"},"body":"Heya,\n\nOn Tue, May 19, 2009 at 18:09, Aaron Gray\n<aaronngray.lists@googlemail.com> wrote:\n> I have done a 'git fetch' but the repo is not being updated to latest changes.\n\nFetch only 'fetches' the data, it doesn't update your working copy. To\nget your working copy up to date you can do 'git merge origin' after\nyou do 'git fetch origin'. That is such a common operation that there\nis a single command that does just that, 'git pull origin' will do\nwhat you want :).\n\n-- \nCheers,\n\nSverre Rabbelier\n"}]}