{"thread":{"id":"16000","subject":"git history and file moves","startedAt":"2008-10-22T02:02:47Z","lastAt":"2008-10-24T22:13:02Z","messageCount":7,"participants":["Lin Ming","Alex Riesen","Michael J Gruber","Moore, Robert","Jakub Narebski"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"93644","messageId":"1224640967.14280.0.camel@minggr.sh.intel.com","threadId":"16000","inReplyTo":null,"subject":"git history and file moves","fromName":"Lin Ming","fromEmail":"ming.m.lin@intel.com","sentAt":"2008-10-22T02:02:47Z","receivedAt":"2008-10-22T02:02:47Z","isPatch":false,"sender":{"key":"ming.m.lin@intel.com","avatar":null},"body":"﻿I'm looking for a way to move files to a new directory and have the\nfull history follow the file automatically. Is this possible?\n\nI know about --follow, but I want the history to just follow the file\ntransparently. Also, we have a git web interface and we want the full\nhistory for the moved files to be available.\n\nThanks,\nLin Ming\n"},{"id":"93675","messageId":"81b0412b0810220419q43f6985fs1c608e3d3cbcf8f3@mail.gmail.com","threadId":"16000","inReplyTo":"1224640967.14280.0.camel@minggr.sh.intel.com","subject":"Re: git history and file moves","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2008-10-22T11:19:26Z","receivedAt":"2008-10-22T11:19:26Z","isPatch":false,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"2008/10/22 Lin Ming <ming.m.lin@intel.com>:\n> I'm looking for a way to move files to a new directory and have the\n> full history follow the file automatically. Is this possible?\n>\n> I know about --follow, but I want the history to just follow the file\n> transparently. ...\n\nOf all Git tools, what does not do this \"transparently\" or \"automatically\"?\nHow more transparent do you imagine this?\nWhat do you think should follow what?\n\nI ask, because it is hard to understand what exactly is it you're missing:\nmerge support (which we have), git log listing the files as copied/renamed\n(which is what --follow is for, and the suggestion for you is to make an\nalias or something), git blame (ever looked at git gui blame?) or gitk\n(which follows renames in default configuration)\n\n> Also, we have a git web interface and we want the full\n> history for the moved files to be available.\n\nIt is available. Whether it is shown is another question. git-web can\nbe improved (or just configured?)\n"},{"id":"93678","messageId":"48FF1EDB.8010503@drmicha.warpmail.net","threadId":"16000","inReplyTo":"81b0412b0810220419q43f6985fs1c608e3d3cbcf8f3@mail.gmail.com","subject":"Re: git history and file moves","fromName":"Michael J Gruber","fromEmail":"git@drmicha.warpmail.net","sentAt":"2008-10-22T12:38:51Z","receivedAt":"2008-10-22T12:38:51Z","isPatch":false,"sender":{"key":"git@grubix.eu","avatar":"https://avatars.githubusercontent.com/u/233215?v=4"},"body":"Alex Riesen venit, vidit, dixit 10/22/08 13:19:\n> 2008/10/22 Lin Ming <ming.m.lin@intel.com>:\n>> I'm looking for a way to move files to a new directory and have the\n>> full history follow the file automatically. Is this possible?\n>>\n>> I know about --follow, but I want the history to just follow the file\n>> transparently. ...\n> \n> Of all Git tools, what does not do this \"transparently\" or \"automatically\"?\n> How more transparent do you imagine this?\n> What do you think should follow what?\n> \n> I ask, because it is hard to understand what exactly is it you're missing:\n> merge support (which we have), git log listing the files as copied/renamed\n> (which is what --follow is for, and the suggestion for you is to make an\n> alias or something), git blame (ever looked at git gui blame?) or gitk\n> (which follows renames in default configuration)\n> \n>> Also, we have a git web interface and we want the full\n>> history for the moved files to be available.\n> \n> It is available. Whether it is shown is another question. git-web can\n> be improved (or just configured?)\n\nBy default, gitweb uses \"-M\" for diff. You can specify all options (-C,\n-CC, -B) using  \"@diff_opts\" in the config file for gitweb.cgi - if that\nis what you are using. Is it?\n\nAnyways, using default configs for git log and gitweb.cgi both of them\nshow the full history (renames, history before and after) for me here,\nusing current git (1.6.0.3.514.g2f91b). What is your setup?\n\nMichael\n"},{"id":"93884","messageId":"4911F71203A09E4D9981D27F9D8308580AA7FFFB@orsmsx503.amr.corp.intel.com","threadId":"16000","inReplyTo":"48FF1EDB.8010503@drmicha.warpmail.net","subject":"RE: git history and file moves","fromName":"Moore, Robert","fromEmail":"robert.moore@intel.com","sentAt":"2008-10-24T21:30:46Z","receivedAt":"2008-10-24T21:30:46Z","isPatch":false,"sender":{"key":"robert.moore@intel.com","avatar":"https://gravatar.com/avatar/1297935bfacfdb19618287d49b72b098d10ce8c5989d548962d3da1b1c8373fb?d=mp&s=160"},"body":"Here's what we have:\n\n/var/www/cgi-bin/gitweb.acpica/gitweb.conf\n\nContaints this : GITWEB_CSS = \"/icons/gitweb.css\";\n\n\nWhat should we add to automatically get all file history?\n\nThanks,\nBob\n\n>-----Original Message-----\n>From: Michael J Gruber [mailto:git@drmicha.warpmail.net]\n>Sent: Wednesday, October 22, 2008 5:39 AM\n>To: Lin, Ming M\n>Cc: Alex Riesen; git@vger.kernel.org; Moore, Robert\n>Subject: Re: git history and file moves\n>\n>Alex Riesen venit, vidit, dixit 10/22/08 13:19:\n>> 2008/10/22 Lin Ming <ming.m.lin@intel.com>:\n>>> I'm looking for a way to move files to a new directory and have the\n>>> full history follow the file automatically. Is this possible?\n>>>\n>>> I know about --follow, but I want the history to just follow the file\n>>> transparently. ...\n>>\n>> Of all Git tools, what does not do this \"transparently\" or\n>\"automatically\"?\n>> How more transparent do you imagine this?\n>> What do you think should follow what?\n>>\n>> I ask, because it is hard to understand what exactly is it you're\n>missing:\n>> merge support (which we have), git log listing the files as\n>copied/renamed\n>> (which is what --follow is for, and the suggestion for you is to make an\n>> alias or something), git blame (ever looked at git gui blame?) or gitk\n>> (which follows renames in default configuration)\n>>\n>>> Also, we have a git web interface and we want the full\n>>> history for the moved files to be available.\n>>\n>> It is available. Whether it is shown is another question. git-web can\n>> be improved (or just configured?)\n>\n>By default, gitweb uses \"-M\" for diff. You can specify all options (-C,\n>-CC, -B) using  \"@diff_opts\" in the config file for gitweb.cgi - if that\n>is what you are using. Is it?\n>\n>Anyways, using default configs for git log and gitweb.cgi both of them\n>show the full history (renames, history before and after) for me here,\n>using current git (1.6.0.3.514.g2f91b). What is your setup?\n>\n>Michael\n"},{"id":"93885","messageId":"81b0412b0810241443t75e2022fg984df400585cb254@mail.gmail.com","threadId":"16000","inReplyTo":"4911F71203A09E4D9981D27F9D8308580AA7FFFB@orsmsx503.amr.corp.intel.com","subject":"Re: git history and file moves","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2008-10-24T21:43:15Z","receivedAt":"2008-10-24T21:43:15Z","isPatch":false,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"2008/10/24 Moore, Robert <robert.moore@intel.com>:\n> Here's what we have:\n>\n> /var/www/cgi-bin/gitweb.acpica/gitweb.conf\n>\n> Containts this : GITWEB_CSS = \"/icons/gitweb.css\";\n>\n> What should we add to automatically get all file history?\n>\n\nNothing. It is the default. You can change the variable Michael\nmentioned to use \"-M -M -C -C\" but it is very-very slow on any\nkind of history worth its commits.\n\nAnd you almost never talk about _file_ history in Git. It is all\n_project_ history, filtered for commits which touch the file you're\ninterested in at the moment of looking.\n"},{"id":"93888","messageId":"4911F71203A09E4D9981D27F9D8308580AA80062@orsmsx503.amr.corp.intel.com","threadId":"16000","inReplyTo":"81b0412b0810241443t75e2022fg984df400585cb254@mail.gmail.com","subject":"RE: git history and file moves","fromName":"Moore, Robert","fromEmail":"robert.moore@intel.com","sentAt":"2008-10-24T22:01:40Z","receivedAt":"2008-10-24T22:01:40Z","isPatch":false,"sender":{"key":"robert.moore@intel.com","avatar":"https://gravatar.com/avatar/1297935bfacfdb19618287d49b72b098d10ce8c5989d548962d3da1b1c8373fb?d=mp&s=160"},"body":"What we are seeing is an issue after we do a file move to a new directory. Once moved, the previous history of the file is not readily available. One needs to know to use --follow on the command line, and worse, gitweb does not show the full history at all.\n\nWe have almost a decade of history on the project, from several different source control systems. We often find it useful to go back and find out when something changed, so we want to keep it and have it easily available.\n\n>-----Original Message-----\n>From: Alex Riesen [mailto:raa.lkml@gmail.com]\n>Sent: Friday, October 24, 2008 2:43 PM\n>To: Moore, Robert\n>Cc: Michael J Gruber; Lin, Ming M; git@vger.kernel.org\n>Subject: Re: git history and file moves\n>\n>2008/10/24 Moore, Robert <robert.moore@intel.com>:\n>> Here's what we have:\n>>\n>> /var/www/cgi-bin/gitweb.acpica/gitweb.conf\n>>\n>> Containts this : GITWEB_CSS = \"/icons/gitweb.css\";\n>>\n>> What should we add to automatically get all file history?\n>>\n>\n>Nothing. It is the default. You can change the variable Michael\n>mentioned to use \"-M -M -C -C\" but it is very-very slow on any\n>kind of history worth its commits.\n>\n>And you almost never talk about _file_ history in Git. It is all\n>_project_ history, filtered for commits which touch the file you're\n>interested in at the moment of looking.\n"},{"id":"93889","messageId":"m3vdvhhc5s.fsf@localhost.localdomain","threadId":"16000","inReplyTo":"4911F71203A09E4D9981D27F9D8308580AA7FFFB@orsmsx503.amr.corp.intel.com","subject":"Re: git history and file moves","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2008-10-24T22:13:02Z","receivedAt":"2008-10-24T22:13:02Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"\"Moore, Robert\" <robert.moore@intel.com> writes:\n\n> \n> Thanks,\n> Bob\n> \n> >-----Original Message-----\n>Michael J Gruber wrote:\n>>Alex Riesen venit, vidit, dixit 10/22/08 13:19:\n>>> 2008/10/22 Lin Ming <ming.m.lin@intel.com>:\n\n>>>> I'm looking for a way to move files to a new directory and have the\n>>>> full history follow the file automatically. Is this possible?\n>>>>\n>>>> I know about --follow, but I want the history to just follow the file\n>>>> transparently. ...\n>>>\n>>> Of all Git tools, what does not do this \"transparently\" or \"automatically\"?\n[...]\n\n>>>> Also, we have a git web interface and we want the full\n>>>> history for the moved files to be available.\n>>>\n>>> It is available. Whether it is shown is another question. git-web can\n>>> be improved (or just configured?)\n>>\n>> By default, gitweb uses \"-M\" for diff. You can specify all options (-C,\n>> -CC, -B) using  \"@diff_opts\" in the config file for gitweb.cgi - if that\n>> is what you are using. Is it?\n>>\n>> Anyways, using default configs for git log and gitweb.cgi both of them\n>> show the full history (renames, history before and after) for me here,\n>> using current git (1.6.0.3.514.g2f91b). What is your setup?\n>\n> Here's what we have:\n> \n> /var/www/cgi-bin/gitweb.acpica/gitweb.conf\n> \n> Containts this : GITWEB_CSS = \"/icons/gitweb.css\";\n\nThis fragment has nothing to do with rename (file movement) detection.\n\n> \n> What should we add to automatically get all file history?\n\nWhile the 'commitdiff' view would, in default gitweb configuration,\ncontain information about file renames, currently 'history' view does\nnot support '--follow' option to git-log.  It wouldn't be too hard to\nadd it, but it just wasn't done (well, add to this the fact that\n--follow works only for simple cases).\n\n-- \nJakub Narebski\nPoland\nShadeHawk on #git\n"}]}