git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: git-filter-branch

From
Mike Hommey <mh@glandium.org>
Date
Aug 9, 2007, 09:30 UTC
Message-ID
<20070809093051.GA21458@glandium.org>
In-Reply-To
<Pine.LNX.4.64.0708091018340.21857@racer.site>
On Thu, Aug 09, 2007 at 10:19:20AM +0100, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:
Show 17 quoted lines
> > In the description in the manpage:
> >    Lets you rewrite git revision history by creating a new branch from
> >    your current branch, applying custom filters on each revision.
> >    (...)
> >    The command takes the new branch name as a mandatory argument and the
> >    filters as optional arguments
> > 
> > And in example:
> >    Now, you will get the rewritten history saved in the branch newbranch
> >    (your current branch is left untouched).
> > 
> > I must say this is a feature that would actually be nice to have...
> 
> To compare with the old one?  Use reflogs:
> 
> 	git filter-branch --some-option master
> 	git diff master@{1}..master

To have, for example, a branch tracking an upstream (svn or whatever) repository and have a branch based on it, only differing in the fact that some directories get removed.

To be more specific, I'm tracking webkit's svn repository, and want to have a branch which would be a base for making source tarballs for debian, excluding a lot of cruft (such as LayoutTests which are *huge*, or the website that also lives in the same svn trunk).

As files are added frequently in these directories, rebase or merge would not be enough, and I'd like to be able to do this with a bare repository, which rebase and merge don't allow me to...

So if you have a better idea than git-filter-branch for that, I'm open to suggestions ;)

Cheers,
Mike
Previous: Johannes SchindelinNext: Johannes Schindelin
Message 5 of 6 in “git-filter-branch”
  1. Mike HommeyAug 9, 2007
  2. Johannes SchindelinAug 9, 2007
  3. Mike HommeyAug 9, 2007
  4. Johannes SchindelinAug 9, 2007
  5. Mike HommeyAug 9, 2007
  6. Johannes SchindelinAug 9, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.