{"thread":{"id":"22949","subject":"sub module branches","startedAt":"2010-03-08T11:14:55Z","lastAt":"2010-03-09T00:47:13Z","messageCount":3,"participants":["Mahesh Vaidya","Peter Krefting","Avery Pennarun"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"136383","messageId":"b42431c81003080314j694114b5o433988470f13328a@mail.gmail.com","threadId":"22949","inReplyTo":null,"subject":"sub module branches","fromName":"Mahesh Vaidya","fromEmail":"forvaidya@gmail.com","sentAt":"2010-03-08T11:14:55Z","receivedAt":"2010-03-08T11:14:55Z","isPatch":false,"sender":{"key":"forvaidya@gmail.com","avatar":null},"body":"Hi\n\nI have a situation like\n\nproject/source.git\n           /submod_1\n           /submod_2\n\nI need to modify code in all 3 repos viz. source, submod_1 & submod_2.\n\nIf I create branch in source, will it propogate to remaining\nsubmodules ? or in other words can I have \"global branch\" and \"global\ntag\"\n\nThx/\n\nMahesh.\n"},{"id":"136389","messageId":"alpine.DEB.2.00.1003081403110.30270@ds9.cixit.se","threadId":"22949","inReplyTo":"b42431c81003080314j694114b5o433988470f13328a@mail.gmail.com","subject":"Re: sub module branches","fromName":"Peter Krefting","fromEmail":"peter@softwolves.pp.se","sentAt":"2010-03-08T13:05:31Z","receivedAt":"2010-03-08T13:05:31Z","isPatch":false,"sender":{"key":"peter@softwolves.pp.se","avatar":"https://avatars.githubusercontent.com/u/990764?v=4"},"body":"Mahesh Vaidya:\n\n> If I create branch in source, will it propogate to remaining submodules ?\n\nNo, the branch is only created in the top-level module.\n\n> or in other words can I have \"global branch\" and \"global tag\"\n\nThe branch is \"global\" in the way that it does contain a reference to the \ncurrent commit of the submodule. You do not *need* to have a local branch \nin the submodule to change where it pointed to from the top-level module. It \ndoes help to have it, though, as you eventually probably will want to push \nyour changes somewhere, and then you need to have a symbolic reference in \nthe submodule(s) you have branched as well.\n\n-- \n\\\\// Peter - http://www.softwolves.pp.se/\n"},{"id":"136442","messageId":"32541b131003081647j2eadb8dfs758611fd4007deea@mail.gmail.com","threadId":"22949","inReplyTo":"b42431c81003080314j694114b5o433988470f13328a@mail.gmail.com","subject":"Re: sub module branches","fromName":"Avery Pennarun","fromEmail":"apenwarr@gmail.com","sentAt":"2010-03-09T00:47:13Z","receivedAt":"2010-03-09T00:47:13Z","isPatch":false,"sender":{"key":"apenwarr@gmail.com","avatar":"https://avatars.githubusercontent.com/u/20592?v=4"},"body":"On Mon, Mar 8, 2010 at 6:14 AM, Mahesh Vaidya <forvaidya@gmail.com> wrote:\n> I have a situation like\n>\n> project/source.git\n>           /submod_1\n>           /submod_2\n>\n> I need to modify code in all 3 repos viz. source, submod_1 & submod_2.\n>\n> If I create branch in source, will it propogate to remaining\n> submodules ? or in other words can I have \"global branch\" and \"global\n> tag\"\n\nYou could use git-subtree instead: http://github.com/apenwarr/git-subtree\n\nThat will allow you to branch all the repos at once.  It slightly\nincreases the effort required to extract the changes and submit them\nupstream again, though.\n\nHave fun,\n\nAvery\n"}]}