# [PATCH v2] Allow format-patch to create patches for merges

2 messages from 2009-01-26 to 2009-01-26. Participants: Nathan W. Panike, Sverre Rabbelier.
Thread: https://gitlist.dev/t/17376

## Nathan W. Panike, 2009-01-26 16:43

Subject: [PATCH v2] Allow format-patch to create patches for merges
Message-ID: <1232988212-8613-1-git-send-email-nathan.panike@gmail.com>
URL: https://gitlist.dev/e/1232988212-8613-1-git-send-email-nathan.panike%40gmail.com

```
The behavior for git format-patch is to ignore merge commits, producing an
empty patch.  The code does not allow the user to change this behavior. This
patch changes that behavior by allowing the user to specify -c or -m at the
command line to produce a patch for a merge commit.

Signed-off-by: Nathan W. Panike <nathan.panike@gmail.com>
---
Add Sign off.

This seems to solve my problem, but maybe my workflow is sufficiently different
that it is a problem no one else has. Maybe someone can point me in a direction
that solves problems more users have.

Thanks,

Nathan Panike
 builtin-log.c |    4 ----
 1 files changed, 0 insertions(+), 4 deletions(-)

diff --git a/builtin-log.c b/builtin-log.c
index 2ae39af..ea4729d 100644
--- a/builtin-log.c
+++ b/builtin-log.c
@@ -994,10 +994,6 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix)
 			continue;
 		}
 
-		/* ignore merges */
-		if (commit->parents && commit->parents->next)
-			continue;
-
 		if (ignore_if_in_upstream &&
 				has_commit_patch_id(commit, &ids))
 			continue;
-- 
1.6.1.1.GIT

```

## Sverre Rabbelier, 2009-01-26 19:34

Subject: Re: [PATCH v2] Allow format-patch to create patches for merges
Message-ID: <bd6139dc0901261134n1ad61992t64d36135a6756eaa@mail.gmail.com>
URL: https://gitlist.dev/e/bd6139dc0901261134n1ad61992t64d36135a6756eaa%40mail.gmail.com
In-Reply-To: <1232988212-8613-1-git-send-email-nathan.panike@gmail.com>

```
On Mon, Jan 26, 2009 at 17:43, Nathan W. Panike <nathan.panike@gmail.com> wrote:
> This seems to solve my problem, but maybe my workflow is sufficiently different
> that it is a problem no one else has. Maybe someone can point me in a direction
> that solves problems more users have.

It seems like you want to use bundles instead of patches? Since you're
using it just to propagate your changes...?

-- 
Cheers,

Sverre Rabbelier

```
