Dan Hart

Monthly Archives: December 2012

Git show the conflicting commit during a rebase

Posted on December 12, 2012 by Dan Hart
2

To view the failed patch’s commit you can use the following bash function:

function show_patch() {
  git show $(head -1 .git/rebase-apply/${1} | awk '{ print $2 }')
}

Put it in your .bash_profile or similar.

Example useage:

show_patch 0001

Copy the patch number from git’s output message e.g. “Patch failed at 0001″

Posted in General | 2 Replies

Categories

  • Chef Cookbooks
  • Debian
  • General
  • Git
  • Linux
  • NGINX
  • PHP
  • Vagrant

Archives

  • December 2012
  • November 2011