[BUG] rebase -p loses commits

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I was trying to reproduce somebody's issue with a minimal test case, and
I ran across this setup wherein "rebase -p" silently drops some commits:

  commit() {
    echo $1 >file && git add file && git commit -m $1
  }

  # repo with two branches, each with conflicting content
  git init repo && cd repo &&
  commit base &&
  commit master &&
  git checkout -b feature HEAD^ &&
  commit feature &&

  # now merge them, with some fake resolution
  ! git merge master &&
  commit resolved &&

  # now try to "rebase -p" on top of master.
  git rebase -p master

The rebase completes successfully, but the "feature" commit and the
merge resolution are gone!

I'm totally unfamiliar with the preserve-merges code, and I won't have
time to dig further until later today or tomorrow, so I thought I'd
throw it out here and see if anybody has any clues.

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]