···44slug: pulls
55title: the lifecycle of a pull request
66subtitle: we shipped a bunch of PR features recently; here's how we built it
77-date: 2025-04-15
77+date: 2025-04-16
88+image: /static/img/hidden-ref.png
89authors:
910 - name: Anirudh
1011 email: anirudh@tangled.sh
···43444445<figure class="max-w-[550px] m-auto flex flex-col items-center justify-center">
4546 <img class="h-auto max-w-full" src="/static/img/merge-base.png">
4646- <figcaption class="text-center">Merge base caption here! [!!!change this!]</figcaption>
4747+ <figcaption class="text-center"><code>A</code> is the merge-base for
4848+<code>feature</code> and <code>main</code>.</figcaption>
4749</figure>
48504951Your `feature` branch has advanced 2 commits since you first
···51532 commits. Doing a trivial `git diff feature main` will
5254produce a confusing patch:
53555454-- the patch will apply the changes from X and Y
5555-- the patch will **revert** the changes from B and C
5656+- the patch will apply the changes from `X` and `Y`
5757+- the patch will **revert** the changes from `B` and `C`
56585759We obviously do not want the second part! To only show the
5860changes added by `feature`, we have to identify the
···6769### ref comparisons across forks
68706971The plumbing described above is easy to do across two
7070-branches, but what about forks? and what if they live on
7171-different servers altogether (as they can in tangled!)?
7272+branches, but what about forks? And what if they live on
7373+different servers altogether (as they can in Tangled!)?
72747375Here's the concept: since we already have all the necessary
7476components to compare two local refs, why not simply
···172174173175* Change ID support: This will allow us to group changes
174176 together and track them across multiple commits, and to
175175- provide "history" for each change. This works great with
176176- `jujutsu`.
177177+ provide "history" for each change. This works great with [Jujutsu][jj].
178178+179179+Oh and lastly, we have a [Discord](https://discord.gg/W7SRR4xHhd). We'll
180180+see you there!
181181+182182+[jj]: https://jj-vcs.github.io/jj/latest/