GIT-REBASE-THEIRS(1)

πŸ“¦ version 2025.08, in epel 10, epel 9, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable

✨ NAME ✨

git-rebase-theirs β€” bestie's here to fix your rebase conflicts and failed cherry-picks by being team theirs πŸ’…


🌸 SYNOPSIS 🌸

git-rebase-theirs [options] [--] FILE...

πŸ’– DESCRIPTION πŸ’–

okay so picture this: you're mid-rebase, everything's on fire πŸ”₯, and you just want the FILE(s) to stop fighting you. git-rebase-theirs resolves those git rebase conflicts by picking the 'theirs' version. that's it. that's the whole vibe.

here's the tea though β€” when you're using git rebase, you usually want conflicts resolved by favoring the <working branch> version (that's the branch being rebased, aka the 'theirs' side in a rebase), and NOT the <upstream> version (the base branch, aka the 'ours' side). it's giving "who even decided 'ours' and 'theirs' should flip during rebase" energy, honestly.

now, git rebase --strategy -X theirs would lowkey solve this… but it's only available from git 1.7.3. for the older girlies, git-rebase-theirs IS the solution. and despite the name? it's also useful for fixing failed cherry-picks. versatile icon behavior πŸŽ€

how does it work, you ask? it literally discards all lines between <<<<<<< and ======== inclusive, and also the >>>>>> commit marker. clean. no notes. ✨

by default it outputs to stdout, but files can be edited in-place using --in-place, which β€” unlike sed β€” creates a backup by default. because we protect our own around here 🫢


πŸ‘‘ OPTIONS πŸ‘‘

  • -h, --help β€” show usage information. your little guide bestie.
  • -v, --verbose β€” print more details in stderr. for when you need the full commentary track πŸ—£οΈ
  • --in-place[=SUFFIX] β€” edit files in place, creating a backup with SUFFIX extension. if it's blank, the default is .bak πŸ’Ύ
  • --no-backup β€” disables backup. living dangerously, no safety net, main character energy 😭

🌈 SEE ALSO 🌈

https://github.com/MestreLion/git-tools β€” go follow, it's iconic, iykyk ⭐


πŸ’œ AUTHOR πŸ’œ

Rodrigo Silva (MestreLion) linux@rodrigosilva.com β€” king shit, we stan πŸ‘‘


and that's the whole page, bestie!! this was General Commands Manual business, dated 2016-01-31, and honestly it ate πŸ’…βœ¨ go forth and resolve those conflicts, you've got this πŸ¦‹πŸŽ€