{"thread":{"id":"4613","subject":"git pull w/o checkout?","startedAt":"2006-06-22T12:51:56Z","lastAt":"2006-06-22T13:34:25Z","messageCount":12,"participants":["Kumar Gala","Jeff King","Matthias Kestenholz","Jakub Narebski","Mathieu Chouquet-Stringer"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"22262","messageId":"E65F8DB5-677B-4C7B-A4EC-5F6FB76D6E9A@kernel.crashing.org","threadId":"4613","inReplyTo":null,"subject":"git pull w/o checkout?","fromName":"Kumar Gala","fromEmail":"galak@kernel.crashing.org","sentAt":"2006-06-22T12:51:56Z","receivedAt":"2006-06-22T12:51:56Z","isPatch":false,"sender":{"key":"galak@kernel.crashing.org","avatar":null},"body":"I trying to see if there is a way to get the effect of a git-pull w/o  \ngetting the checked out files.\n\nAny ideas?\n\nthanks\n\n- kumar\n"},{"id":"22263","messageId":"20060622130523.GA6893@coredump.intra.peff.net","threadId":"4613","inReplyTo":"E65F8DB5-677B-4C7B-A4EC-5F6FB76D6E9A@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2006-06-22T13:05:24Z","receivedAt":"2006-06-22T13:05:24Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Jun 22, 2006 at 07:51:56AM -0500, Kumar Gala wrote:\n\n> I trying to see if there is a way to get the effect of a git-pull w/o  \n> getting the checked out files.\n\ngit-fetch?\n\n-Peff\n"},{"id":"22264","messageId":"E333ADD9-1096-4137-9D72-D58A8E2A5582@kernel.crashing.org","threadId":"4613","inReplyTo":"20060622130523.GA6893@coredump.intra.peff.net","subject":"Re: git pull w/o checkout?","fromName":"Kumar Gala","fromEmail":"galak@kernel.crashing.org","sentAt":"2006-06-22T13:10:10Z","receivedAt":"2006-06-22T13:10:10Z","isPatch":false,"sender":{"key":"galak@kernel.crashing.org","avatar":null},"body":"\nOn Jun 22, 2006, at 8:05 AM, Jeff King wrote:\n\n> On Thu, Jun 22, 2006 at 07:51:56AM -0500, Kumar Gala wrote:\n>\n>> I trying to see if there is a way to get the effect of a git-pull w/o\n>> getting the checked out files.\n>\n> git-fetch?\n\nIts the first half, still need to resolve FETCH_HEAD, HEAD, etc..\n\n- k\n"},{"id":"22265","messageId":"20060622131129.GB5134@spinlock.ch","threadId":"4613","inReplyTo":"E65F8DB5-677B-4C7B-A4EC-5F6FB76D6E9A@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Matthias Kestenholz","fromEmail":"lists@spinlock.ch","sentAt":"2006-06-22T13:11:29Z","receivedAt":"2006-06-22T13:11:29Z","isPatch":false,"sender":{"key":"lists@spinlock.ch","avatar":null},"body":"* Kumar Gala (galak@kernel.crashing.org) wrote:\n> I trying to see if there is a way to get the effect of a git-pull w/o  \n> getting the checked out files.\n> \n> Any ideas?\n\nDo you want to fetch remote changes without merging them into your\nworking tree? If you, \"git fetch\" is your friend.\n\nBy the way, pull does the equivalent of a fetch and a subsequent\nmerge.\n\n\tMatthias\n"},{"id":"22267","messageId":"20060622131344.GA7168@coredump.intra.peff.net","threadId":"4613","inReplyTo":"E333ADD9-1096-4137-9D72-D58A8E2A5582@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2006-06-22T13:13:44Z","receivedAt":"2006-06-22T13:13:44Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Jun 22, 2006 at 08:10:10AM -0500, Kumar Gala wrote:\n\n> >git-fetch?\n> Its the first half, still need to resolve FETCH_HEAD, HEAD, etc..\n\nCan you elaborate on what you're trying to accomplish?\n\n-Peff\n"},{"id":"22268","messageId":"6F96D77C-FE27-4B74-ADBF-9964B5FD72DF@kernel.crashing.org","threadId":"4613","inReplyTo":"20060622131129.GB5134@spinlock.ch","subject":"Re: git pull w/o checkout?","fromName":"Kumar Gala","fromEmail":"galak@kernel.crashing.org","sentAt":"2006-06-22T13:13:54Z","receivedAt":"2006-06-22T13:13:54Z","isPatch":false,"sender":{"key":"galak@kernel.crashing.org","avatar":null},"body":"\nOn Jun 22, 2006, at 8:11 AM, Matthias Kestenholz wrote:\n\n> * Kumar Gala (galak@kernel.crashing.org) wrote:\n>> I trying to see if there is a way to get the effect of a git-pull w/o\n>> getting the checked out files.\n>>\n>> Any ideas?\n>\n> Do you want to fetch remote changes without merging them into your\n> working tree? If you, \"git fetch\" is your friend.\n\nthat's what I want, however fetch isn't updating any refs/ as far as  \nI can tell.\n\n> By the way, pull does the equivalent of a fetch and a subsequent\n> merge.\n\nright, its the merge that seems to be doing the checkout.\n\n- k\n"},{"id":"22269","messageId":"A4C01915-3337-460C-BE19-7AC17249BE50@kernel.crashing.org","threadId":"4613","inReplyTo":"20060622131344.GA7168@coredump.intra.peff.net","subject":"Re: git pull w/o checkout?","fromName":"Kumar Gala","fromEmail":"galak@kernel.crashing.org","sentAt":"2006-06-22T13:15:31Z","receivedAt":"2006-06-22T13:15:31Z","isPatch":false,"sender":{"key":"galak@kernel.crashing.org","avatar":null},"body":"\nOn Jun 22, 2006, at 8:13 AM, Jeff King wrote:\n\n> On Thu, Jun 22, 2006 at 08:10:10AM -0500, Kumar Gala wrote:\n>\n>>> git-fetch?\n>> Its the first half, still need to resolve FETCH_HEAD, HEAD, etc..\n>\n> Can you elaborate on what you're trying to accomplish?\n\nA local mirror of a git tree.  I can do the clone easy enough, its  \ntrying to figure out the updates after the fact that is the issue.\n\n- k\n"},{"id":"22270","messageId":"20060622131730.GB7168@coredump.intra.peff.net","threadId":"4613","inReplyTo":"6F96D77C-FE27-4B74-ADBF-9964B5FD72DF@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2006-06-22T13:17:30Z","receivedAt":"2006-06-22T13:17:30Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Jun 22, 2006 at 08:13:54AM -0500, Kumar Gala wrote:\n\n> that's what I want, however fetch isn't updating any refs/ as far as  \n> I can tell.\n\nIt won't update the ref for the branch you're on; it will update the\nhead for the remotes (try running git-show-branch before and after your\nfetch, and you should see an update on 'origin' or whatever remote\nyou're fetching).\n\n-Peff\n"},{"id":"22272","messageId":"6C519A4B-9253-49BB-BF68-DCD557DACCB7@kernel.crashing.org","threadId":"4613","inReplyTo":"20060622131730.GB7168@coredump.intra.peff.net","subject":"Re: git pull w/o checkout?","fromName":"Kumar Gala","fromEmail":"galak@kernel.crashing.org","sentAt":"2006-06-22T13:20:51Z","receivedAt":"2006-06-22T13:20:51Z","isPatch":false,"sender":{"key":"galak@kernel.crashing.org","avatar":null},"body":"\nOn Jun 22, 2006, at 8:17 AM, Jeff King wrote:\n\n> On Thu, Jun 22, 2006 at 08:13:54AM -0500, Kumar Gala wrote:\n>\n>> that's what I want, however fetch isn't updating any refs/ as far as\n>> I can tell.\n>\n> It won't update the ref for the branch you're on; it will update the\n> head for the remotes (try running git-show-branch before and after  \n> your\n> fetch, and you should see an update on 'origin' or whatever remote\n> you're fetching).\n\nAhh, I see.  I can than just copy the 'origin' ref over 'master'.\n\nthanks\n\n- kumar\n"},{"id":"22273","messageId":"20060622132500.GA7954@coredump.intra.peff.net","threadId":"4613","inReplyTo":"6C519A4B-9253-49BB-BF68-DCD557DACCB7@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2006-06-22T13:25:00Z","receivedAt":"2006-06-22T13:25:00Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Thu, Jun 22, 2006 at 08:20:51AM -0500, Kumar Gala wrote:\n\n> Ahh, I see.  I can than just copy the 'origin' ref over 'master'.\n\nYou can, though I'm not sure you even need to. If you're simply wanting\nto mirror a git branch without checking out, then you're already done.\nThe mirror is just in 'origin', not 'master'.\n\n-Peff\n"},{"id":"22275","messageId":"e7e65f$dhf$1@sea.gmane.org","threadId":"4613","inReplyTo":"A4C01915-3337-460C-BE19-7AC17249BE50@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-06-22T13:32:31Z","receivedAt":"2006-06-22T13:32:31Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Kumar Gala wrote:\n\n> \n> On Jun 22, 2006, at 8:13 AM, Jeff King wrote:\n> \n>> On Thu, Jun 22, 2006 at 08:10:10AM -0500, Kumar Gala wrote:\n>>\n>>>> git-fetch?\n>>> Its the first half, still need to resolve FETCH_HEAD, HEAD, etc..\n>>\n>> Can you elaborate on what you're trying to accomplish?\n> \n> A local mirror of a git tree.  I can do the clone easy enough, its  \n> trying to figure out the updates after the fact that is the issue.\n\nAssuming typical configuration, with the following in remotes/origin\n\n---[ <path-to-repo>/.git/remotes/origin ]----\nURL: git://git.kernel.org/pub/scm/git/git.git\nPull: refs/heads/master:refs/heads/origin\nPull:+refs/heads/pu:refs/heads/pu\nPull: refs/heads/man:refs/heads/man\nPull: refs/heads/html:refs/heads/html\nPull: refs/heads/next:refs/heads/next\nPull: refs/heads/todo:refs/heads/todo\nPull: refs/heads/maint:refs/heads/maint\n---------------------------------------------\n\nto update your repository, do:\n\n$ git checkout master\n$ git fetch origin\n\nAny branch except listed ot fhose fetched to will do, or even any command\nthat leaves HEAD different than one of the branches fetched to. Everything\nis updated. Then you can do the second part of pull, using\n\n$ git checkout master\n$ git pull . master\n\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"},{"id":"22276","messageId":"m37j39gvq6.fsf@bigip.bigip.mine.nu","threadId":"4613","inReplyTo":"6C519A4B-9253-49BB-BF68-DCD557DACCB7@kernel.crashing.org","subject":"Re: git pull w/o checkout?","fromName":"Mathieu Chouquet-Stringer","fromEmail":"mchouque@free.fr","sentAt":"2006-06-22T13:34:25Z","receivedAt":"2006-06-22T13:34:25Z","isPatch":false,"sender":{"key":"mchouque@free.fr","avatar":null},"body":"galak@kernel.crashing.org (Kumar Gala) writes:\n> Ahh, I see.  I can than just copy the 'origin' ref over 'master'.\n\nOr use git fetch -u ? \n\n-- \nMathieu Chouquet-Stringer                     mchouque@free.fr\n"}]}