From d99177342d725d7fbbd024245697d33c63952ed9 Mon Sep 17 00:00:00 2001 From: Trent Piepho Date: Fri, 30 Mar 2007 17:37:53 -0700 Subject: build: Fix bug with make qrefresh From: Trent Piepho Annoyingly, the Hg mq extension will strip lines starting with "From: " from the patch header. Since the v4l-dvb format commit message contains a line starting with "From: ", it will mess them up. This changes prep_commit_msg to create a decoy "from" line to keep mq from messing up commit messages. Signed-off-by: Trent Piepho --- v4l/scripts/prep_commit_msg.pl | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'v4l/scripts/prep_commit_msg.pl') diff --git a/v4l/scripts/prep_commit_msg.pl b/v4l/scripts/prep_commit_msg.pl index 819009c57..cb0740a5d 100755 --- a/v4l/scripts/prep_commit_msg.pl +++ b/v4l/scripts/prep_commit_msg.pl @@ -62,12 +62,18 @@ if ($diff eq 'qdiff') { open IN, "hg qheader |"; my @header = ; close IN; + if ($#header > 0) { # Use existing header print @header; exit; } # No header, use pre-made log message below + + # Hg will strip lines that start with "From: " from mq patch headers! + # In order to stop it, we insert this extra From line at the top, + # Hg will strip it and then leave the real from line alone. + print "From: $user\n\n"; } print <<"EOF"; # -- cgit v1.2.3