From 1ee1cff0a8e7c8ca0aa4992535de78aa54aebcb3 Mon Sep 17 00:00:00 2001 From: Konstantin Ryabitsev Date: Wed, 31 Aug 2022 17:39:00 -0400 Subject: trailers: ignore merges when looking at the commit log When finding the range of most recent commits for b4 trailers -u, ignore any merge commits. Reported-by: Vishal Verma Link: https://msgid.link/2517d5cdff57048a13e85b9604957b73b69724c3.camel@kernel.org Signed-off-by: Konstantin Ryabitsev --- b4/ez.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/b4/ez.py b/b4/ez.py index 12dbf2c..7187dad 100644 --- a/b4/ez.py +++ b/b4/ez.py @@ -637,7 +637,7 @@ def update_trailers(cmdargs: argparse.Namespace) -> None: # There doesn't appear to be a great way to find the first commit # where we're NOT the committer, so we get all commits since range specified where # we're the committer and stop at the first non-contiguous parent - gitargs = ['log', '-F', f'--committer={myemail}', '--since', cmdargs.since, '--format=%H %P'] + gitargs = ['log', '-F', '--no-merges', f'--committer={myemail}', '--since', cmdargs.since, '--format=%H %P'] lines = b4.git_get_command_lines(None, gitargs) if not lines: logger.critical('CRITICAL: could not find any commits where committer=%s', myemail) -- cgit v1.2.3