{"thread":{"id":"27204","subject":"remove all traces of some files","startedAt":"2011-04-27T19:58:39Z","lastAt":"2011-04-27T20:40:22Z","messageCount":3,"participants":["Eric Frederich","Johannes Sixt","Phil Hord"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"166549","messageId":"BANLkTim_PriowuBH71M2DxxkJ=Y5oAA2uA@mail.gmail.com","threadId":"27204","inReplyTo":null,"subject":"remove all traces of some files","fromName":"Eric Frederich","fromEmail":"eric.frederich@gmail.com","sentAt":"2011-04-27T19:58:39Z","receivedAt":"2011-04-27T19:58:39Z","isPatch":false,"sender":{"key":"eric.frederich@gmail.com","avatar":"https://gravatar.com/avatar/a047bc6d3404a87c923025574cdee9abf57ae9efc1d96c7bbedf30faf47ee12c?d=mp&s=160"},"body":"I have been adding build files (.dll and .so files) to my git\nrepository periodically when I have been doing builds of my project.\nI know I shouldn't be doing this and want to set up some other kind of\nseparate archive or something for built files.\n\nAlthough there are other devs on the project, I am the only one using\nGit.  Everyone else uses AccuRev.\nPersonally, I maintain my own Git repo (with an AccuRev git branch).\n\nI would like to remove all traces of those .dll and .so files if I\ncould in my git repository.\nI realize this would mess with hashes and would ultimately result in a\ncompletely new tree.\nI am fine with that since, as I said, I am the only user of this Git repo.\n\nSo, can this be done?  Can I rebuild the tree preserving commit\nmessages, timestamps, etc but ignoring certain files?\n\nThanks,\n~Eric\n"},{"id":"166553","messageId":"4DB87E9E.8060700@kdbg.org","threadId":"27204","inReplyTo":"BANLkTim_PriowuBH71M2DxxkJ=Y5oAA2uA@mail.gmail.com","subject":"Re: remove all traces of some files","fromName":"Johannes Sixt","fromEmail":"j6t@kdbg.org","sentAt":"2011-04-27T20:37:50Z","receivedAt":"2011-04-27T20:37:50Z","isPatch":false,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"Am 27.04.2011 21:58, schrieb Eric Frederich:\n> I have been adding build files (.dll and .so files) to my git\n> repository periodically when I have been doing builds of my project.\n> I know I shouldn't be doing this and want to set up some other kind of\n> separate archive or something for built files.\n> \n> Although there are other devs on the project, I am the only one using\n> Git.  Everyone else uses AccuRev.\n> Personally, I maintain my own Git repo (with an AccuRev git branch).\n> \n> I would like to remove all traces of those .dll and .so files if I\n> could in my git repository.\n> I realize this would mess with hashes and would ultimately result in a\n> completely new tree.\n> I am fine with that since, as I said, I am the only user of this Git repo.\n> \n> So, can this be done?  Can I rebuild the tree preserving commit\n> messages, timestamps, etc but ignoring certain files?\n\nGet familiar with git-filter-branch --index-filter.\n\n-- Hannes\n"},{"id":"166554","messageId":"4DB87F36.9080901@cisco.com","threadId":"27204","inReplyTo":"BANLkTim_PriowuBH71M2DxxkJ=Y5oAA2uA@mail.gmail.com","subject":"Re: remove all traces of some files","fromName":"Phil Hord","fromEmail":"hordp@cisco.com","sentAt":"2011-04-27T20:40:22Z","receivedAt":"2011-04-27T20:40:22Z","isPatch":false,"sender":{"key":"phil.hord@gmail.com","avatar":"https://avatars.githubusercontent.com/u/123908?v=4"},"body":"On 04/27/2011 03:58 PM, Eric Frederich wrote:\n> I have been adding build files (.dll and .so files) to my git\n> repository periodically when I have been doing builds of my project.\n> I know I shouldn't be doing this and want to set up some other kind of\n> separate archive or something for built files.\n>\n> Although there are other devs on the project, I am the only one using\n> Git.  Everyone else uses AccuRev.\n> Personally, I maintain my own Git repo (with an AccuRev git branch).\n>\n> I would like to remove all traces of those .dll and .so files if I\n> could in my git repository.\n> I realize this would mess with hashes and would ultimately result in a\n> completely new tree.\n> I am fine with that since, as I said, I am the only user of this Git repo.\n>\n> So, can this be done?  Can I rebuild the tree preserving commit\n> messages, timestamps, etc but ignoring certain files?\n\nSomething like this, perhaps:\n  git filter-branch --index-filter \"git rm --cached --ignore-unmatch\n--quiet '*.dll' '*.so' \" -- --all\n\nMore examples here:\n  git filter-branch --help\n\nPhil\n"}]}