$ ./guess_the_languageGit
Git · hard · #19

Whose version of f is now in the working tree?

$ git switch feat
$ git rebase main
CONFLICT (content): Merge conflict in f
$ git checkout --ours f
  1. The common ancestor's
  2. The last stashed version
  3. The version from feat
  4. The version from main
A rebase replays feat commits onto main, so "ours" is the branch being built on (main) and "theirs" is the commit being replayed. The roles are swapped compared with a merge.
Play Git ▸