{"thread":{"id":"2493","subject":"Question on GIT tutorial.","startedAt":"2005-11-14T10:20:23Z","lastAt":"2005-11-18T07:24:02Z","messageCount":3,"participants":["Franck","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"11774","messageId":"cda58cb80511140220n26da3edm@mail.gmail.com","threadId":"2493","inReplyTo":null,"subject":"Question on GIT tutorial.","fromName":"Franck","fromEmail":"vagabon.xyz@gmail.com","sentAt":"2005-11-14T10:20:23Z","receivedAt":"2005-11-14T10:20:23Z","isPatch":false,"sender":{"key":"vagabon.xyz@gmail.com","avatar":null},"body":"Hi,\n\nI have a question about the GIT tutorial. At page 21, there is a\ndescription of \"subsystem maintainer\" work cycle, I don't understand\nwhy point 3 is needed. This point tells:\n\n\"\"\"\nCopy over the packed files from \"project lead\" public repository to\nyour public repository.\n\"\"\"\n\nWhy is it needed ?\n\nThanks\n--\n               Franck\n"},{"id":"12139","messageId":"7vlkznt5tc.fsf@assigned-by-dhcp.cox.net","threadId":"2493","inReplyTo":"cda58cb80511140220n26da3edm@mail.gmail.com","subject":"Re: Question on GIT tutorial.","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2005-11-17T19:47:27Z","receivedAt":"2005-11-17T19:47:27Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Franck <vagabon.xyz@gmail.com> writes:\n\n> Hi,\n>\n> I have a question about the GIT tutorial. At page 21, there is a\n> description of \"subsystem maintainer\" work cycle, I don't understand\n> why point 3 is needed. This point tells:\n>\n> \"\"\"\n> Copy over the packed files from \"project lead\" public repository to\n> your public repository.\n> \"\"\"\n>\n> Why is it needed ?\n\nThat was a remnant from the days some transports did not\nunderstand objects/info/alternates; I think we do not need that\nstep anymore.\n"},{"id":"12197","messageId":"7vd5kyo1v1.fsf@assigned-by-dhcp.cox.net","threadId":"2493","inReplyTo":"7vlkznt5tc.fsf@assigned-by-dhcp.cox.net","subject":"Re: Question on GIT tutorial.","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2005-11-18T07:24:02Z","receivedAt":"2005-11-18T07:24:02Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Junio C Hamano <junkio@cox.net> writes:\n\n>> \"\"\"\n>> Copy over the packed files from \"project lead\" public repository to\n>> your public repository.\n>> \"\"\"\n>>\n>> Why is it needed ?\n>\n> That was a remnant from the days some transports did not\n> understand objects/info/alternates; I think we do not need that\n> step anymore.\n\nAfter re-reading that section, I take it back.  What I meant to\nsay there was this:\n\n   You are the subsystem maintainer, so your tree would have\n   many overlapping objects with your project lead.  So in step\n   2, you prepare an empty repository first, and then in step\n   3., copy the packs from the project lead.  Then pushing into\n   that repository in step 4 would prevent the objects you\n   inherited from your project lead from getting expanded in\n   your public repository.\n\nBut these days, there is a more efficient way *if* your public\nrepository resides on the same machine as the public repository\nof your project lead.  First, on the public repository side:\n\n   pub$ export GIT_DIR=/pub/my.git\n   pub$ HIS_GIT=/pub/his.git\n   pub$ git-init-db\n   pub$ echo \"$HIS_GIT/objects\" >\"$GIT_DIR/objects/info/alternates\"\n   pub$ (cd \"$HIS_GIT/refs\" && tar - heads tags) |\n        (cd \"$GIT_DIR/refs\" && mkdir j.u.n.k && cd j.u.n.k && tar xf -)\n\nThis makes your repository to have the same refs as your\nproject lead has but under funny names.  Then from your primary\ndevelopment repository, you push into your public repository:\n\n   home$ git-send-pack --all ssh://pub.repo.xz/pub/my.git/\n\nThanks to the funny refs you stole from your project lead when\nyou prepared your public repository, this transfer sends only\nobjects the project lead does not have, and your refs.  After\nthis is done, you can get rid of the funny refs you stole from\nyour project lead:\n\n   pub$ cd \"$GIT_DIR/refs\" && rm -fr j.u.n.k\n\nIf your public repository is not on the same machine as your\nproject lead's, objects/info/alternates trick cannot be used, so\nwhat we have in the tutorial section still applies.\n"}]}