git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Stephen R. van den Berg" <srb@cuci.nl>
To: Jakub Narebski <jnareb@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: RFC: grafts generalised
Date: Wed, 2 Jul 2008 19:32:03 +0200	[thread overview]
Message-ID: <20080702173203.GA16235@cuci.nl> (raw)
In-Reply-To: <m3lk0kfdo1.fsf@localhost.localdomain>

Jakub Narebski wrote:
>First, if I remember correctly (from KernelTrap and now defunct Kernel
>Traffic and one issue of Git Traffic) the 'graft' mechanizm was
>created so it would be possible to "graft" (join) historical
>conversion repository with the "current work" git repository (started
>from zero when git was deemed good enough for Linux kernel
>development).

Quite.  Which is exactly the spirit I'm extending here.
I need it to stitch together history, but it needs to be more perfect
than mere connecting parents.

Also, the graft mechanism specifically is intended as a temporary
solution until one uses filter-branch to "finalise" the result into a
proper repository which becomes cloneable.

>The fact that git-filter-branch (and earlier cg-admin-rewrite-hist)
>respects grafts, and rewrites history so that grafts are no-op and are
>not needed further is a bit of side-effect.

I beg to differ.  It's not a side effect, it's the proper way to get
rid of the grafts file.  Grafts are temporary and ugly.  In proper
repositories they are a sign of transition to a proper state.
The proper state is attained by using git filter-branch.

>  So I think that it would
>be better to provide generic git-filter-branch filter which can
>understand this "generalized grafts" file format, or rather
>'description of changes' file.  Put it in contrib/, and here you
>go...

The problem is that the process of fixing history is an iterative one,
which can take many months, and everytime you make a change, the
correctness needs to be viewed using gitk.

For argument sake, consider the repository at hand which I'm trying to
"fix", it has 33000 commits, distributed over eight branches with
roughly 3500 merges over a timeperiod of 13 years.
The eight branches were eight separate CVS repositories which have
intersecting histories, and 3500 merges between CVS repositories (i.e.
branches).

If I need to backpatch a certain patch into history, it is likely that
in order to let the change ripple through, it will take 20000 commits to
be rewritten every time I make a slight change to history.
It's not really workable to ripple through 20000 commits everytime I
make a historical change, yet I need to view the change in gitk.

Using git filter-branch, or git sequencer basically has the same
problem, I need to ripple through most of history to get to a state
which is viewable using gitk again.  That is too long a turnaround
cycle.

Using the proposed grafts format, I can make changes incrementally, and
immediately viewable (though not cloneable) on the local repository using gitk.
Then after making all the necessary changes, one git filter-branch run
will "burn" the changes into the repository proper in one go
(renumbering all tags, branches and merges along the way).
-- 
Sincerely,
           Stephen R. van den Berg.

You are confused; but this is your normal state.

  parent reply	other threads:[~2008-07-02 17:33 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-02 14:35 RFC: grafts generalised Stephen R. van den Berg
2008-07-02 16:35 ` Jakub Narebski
2008-07-02 16:43   ` Michael J Gruber
2008-07-02 17:42     ` Stephen R. van den Berg
2008-07-02 18:25       ` Mike Hommey
2008-07-02 18:34         ` Michael J Gruber
2008-07-02 19:31           ` Stephan Beyer
2008-07-02 19:36             ` Stephan Beyer
2008-07-02 20:42             ` Dmitry Potapov
2008-07-02 23:46               ` Stephan Beyer
2008-07-03  6:05                 ` Stephen R. van den Berg
2008-07-02 18:37         ` Stephen R. van den Berg
2008-07-07  6:28       ` Andreas Ericsson
2008-07-07  6:59         ` Stephen R. van den Berg
2008-07-02 17:32   ` Stephen R. van den Berg [this message]
2008-07-03  0:21     ` Petr Baudis
2008-07-03  7:11       ` Stephen R. van den Berg
2008-07-04  0:43     ` Jakub Narebski
2008-07-02 17:19 ` Dmitry Potapov
2008-07-02 17:58   ` Dmitry Potapov
2008-07-02 18:10     ` Stephen R. van den Berg
2008-07-02 18:33       ` Dmitry Potapov
2008-07-02 20:39       ` Dmitry Potapov
2008-07-02 21:18         ` Stephen R. van den Berg
2008-07-02 21:28           ` Avery Pennarun
2008-07-02 21:27         ` Junio C Hamano
2008-07-02 21:49           ` Junio C Hamano
2008-07-03  0:03             ` Junio C Hamano
2008-07-03  6:02       ` Johannes Sixt
2008-07-03  7:30         ` Stephen R. van den Berg
2008-07-03  7:42           ` Johannes Sixt
2008-07-03  9:37             ` Stephen R. van den Berg
2008-07-02 17:59   ` Stephen R. van den Berg
2008-07-03  0:13 ` Petr Baudis
2008-07-03  0:16   ` Petr Baudis
2008-07-03  0:28     ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080702173203.GA16235@cuci.nl \
    --to=srb@cuci.nl \
    --cc=git@vger.kernel.org \
    --cc=jnareb@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).