{"thread":{"id":"19093","subject":"RE: how to arrange source control?","startedAt":"2009-04-27T22:08:02Z","lastAt":"2009-04-28T16:42:51Z","messageCount":2,"participants":["John Dlugosz"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"112465","messageId":"450196A1AAAE4B42A00A8B27A59278E70AE3EC2C@EXCHANGE.trad.tradestation.com","threadId":"19093","inReplyTo":null,"subject":"RE: how to arrange source control?","fromName":"John Dlugosz","fromEmail":"jdlugosz@tradestation.com","sentAt":"2009-04-27T22:08:02Z","receivedAt":"2009-04-27T22:08:02Z","isPatch":false,"sender":{"key":"jdlugosz@tradestation.com","avatar":null},"body":">> what is the best way to use git? Should I run \"git add .\" in\n'rootdir' or run it in each \n>> application and library?\n>> These libraries are used by all of the applications.\n\nI had a similar issue I discussed on this mailing list a few weeks ago.\n\nIf the apps really are separate apps, from a development perspective,\nyou will want each in a separate repository.  That way you are not\nalways being bothered by totally irrelevant changes by others.\n\nBut, git doesn't like the libraries arranged that way.  If you make each\nlibrary a git submodule, they will all be in a subdirectory under each\napp, not a peer with them.  This does have the advantage that each app\ncould be using a different version of the libs.  If they are meant to be\nreleased as a suite, you will still find that handy during development,\nwhile waiting for the ripple effect to catch up to the top level after\nsomething changes in a lib.\n\nI've not taken it to its logical conclusion of libs that use other libs\nwhich are also used directly by the app.\n\nIf you keep your existing directory structure, you can certainly make\neach lib its own repository, and not rely on git to track specific\nlibrary versions for you.  But I think that will bite you when you need\nto check out something old, such as to make a patch for an existing\nversion or compare behavior against an older version.\n\n--John\n(please forgive the footer; it's not my idea or my choice)\n\n\nTradeStation Group, Inc. is a publicly-traded holding company (NASDAQ GS: TRAD) of three operating subsidiaries, TradeStation Securities, Inc. (Member NYSE, FINRA, SIPC and NFA), TradeStation Technologies, Inc., a trading software and subscription company, and TradeStation Europe Limited, a United Kingdom, FSA-authorized introducing brokerage firm. None of these companies provides trading or investment advice, recommendations or endorsements of any kind. The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited.\n  If you received this in error, please contact the sender and delete the material from any computer.\n"},{"id":"112543","messageId":"450196A1AAAE4B42A00A8B27A59278E70AE3EEB1@EXCHANGE.trad.tradestation.com","threadId":"19093","inReplyTo":"20090428112423.GA28151@ralph","subject":"RE: how to arrange source control?","fromName":"John Dlugosz","fromEmail":"jdlugosz@tradestation.com","sentAt":"2009-04-28T16:42:51Z","receivedAt":"2009-04-28T16:42:51Z","isPatch":false,"sender":{"key":"jdlugosz@tradestation.com","avatar":null},"body":"(back on the list so others can correct what I said)\n\n> So, if you make libraries submodules within an app, does git make a\nnew\n> copy of the library source\n> and put it under the app, or does it just store a different kind of\n> object representing the current\n> state of the library source under the app?\n\nIt looks like copies of the source.  Obviously they are, if the versions\ndiffer!  But git supposedly does some hard linking under the hood, so it\ndoesn't waste disk space.  I don't know if that applies to the working\ndirectory files too, or just to the internal repository implementation\nfiles.\n\n> Is there a way to later automatically merge library changes done in\n> different apps?\n\nNo, it's like any other change.  That library will have its own git repo\nin that subdirectory.  You need to check out a branch, change it, then\npush.  The other apps, even on the same machine, will not use the new\nstuff until you tell it to.  That's a feature -- it will keep pinned to\nwhat it was building against until you are ready to upgrade.\n\n> > I've not taken it to its logical conclusion of libs that use other\n> libs\n> > which are also used directly by the app.\n> \n> Yes, some of my libs use other libs, all of which are used by certain\n> apps.\n> \n> I've never used version control before. I always made a 'snapshot' of\n> code a a milestone, but I'm hoping\n> there is a better way.\n\nAnother way I thought about, that might be just the ticket for you, is\nto make all the apps and libs in your current directory structure into\nsubmodules of a single master suite repository, which doesn't have\nanything in it other than those submodules.\n\n--John\n(mind the footer... here it comes!)\n\nTradeStation Group, Inc. is a publicly-traded holding company (NASDAQ GS: TRAD) of three operating subsidiaries, TradeStation Securities, Inc. (Member NYSE, FINRA, SIPC and NFA), TradeStation Technologies, Inc., a trading software and subscription company, and TradeStation Europe Limited, a United Kingdom, FSA-authorized introducing brokerage firm. None of these companies provides trading or investment advice, recommendations or endorsements of any kind. The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited.\n  If you received this in error, please contact the sender and delete the material from any computer.\n"}]}