aboutsummaryrefslogtreecommitdiff
path: root/git-fmt-merge-msg.perl
diff options
context:
space:
mode:
Diffstat (limited to 'git-fmt-merge-msg.perl')
-rwxr-xr-xgit-fmt-merge-msg.perl8
1 files changed, 8 insertions, 0 deletions
diff --git a/git-fmt-merge-msg.perl b/git-fmt-merge-msg.perl
index afe80e632..5986e5414 100755
--- a/git-fmt-merge-msg.perl
+++ b/git-fmt-merge-msg.perl
@@ -75,6 +75,7 @@ while (<>) {
$src{$src} = {
BRANCH => [],
TAG => [],
+ R_BRANCH => [],
GENERIC => [],
# &1 == has HEAD.
# &2 == has others.
@@ -91,6 +92,11 @@ while (<>) {
push @{$src{$src}{TAG}}, $1;
$src{$src}{HEAD_STATUS} |= 2;
}
+ elsif (/^remote branch (.*)$/) {
+ $origin = $1;
+ push @{$src{$src}{R_BRANCH}}, $1;
+ $src{$src}{HEAD_STATUS} |= 2;
+ }
elsif (/^HEAD$/) {
$origin = $src;
$src{$src}{HEAD_STATUS} |= 1;
@@ -123,6 +129,8 @@ for my $src (@src) {
}
push @this, andjoin("branch ", "branches ",
$src{$src}{BRANCH});
+ push @this, andjoin("remote branch ", "remote branches ",
+ $src{$src}{R_BRANCH});
push @this, andjoin("tag ", "tags ",
$src{$src}{TAG});
push @this, andjoin("commit ", "commits ",