Skip to content

Compare

Two ways to integrate

The same starting state, two integrations side by side. Look at the shape of the history, then look at the file content — the second one is the surprise.

Same files, different history

Both approaches end with an identical working tree. Only the shape of the history differs — that is the whole choice between them: not the work, but the story left behind.

tip: main
b229116 — Merge feature into mainb229116Merge feature into …HEAD → main719f714 — finish the feature719f714finish the featurefeature4d2a685 — start the feature4d2a685start the feature3012841 — main moved on3012841main moved on369dff2 — first369dff2first

1

new commits

0

copied

0

without a card

2

parents on the tip

One new commit with two parents. Nothing is rewritten and nothing is orphaned.

tip: feature
42c75e3 — finish the feature42c75e3finish the featureHEAD → feature43e21f9 — start the feature43e21f9start the feature719f714 — finish the feature (unreachable)719f714finish the feature4d2a685 — start the feature (unreachable)4d2a685start the feature3012841 — main moved on3012841main moved onmain369dff2 — first369dff2first

2

new commits

2

copied

2

without a card

1

parents on the tip

Every feature commit is copied into a new object. The history goes straight; the old boxes stay on the shelf.

Try it yourself in the sandbox