summaryrefslogtreecommitdiff
path: root/Documentation/lint-man-end-blurb.perl
blob: 6bdb13ad9fdb36b8c8f5244fa66fb29c0f619cc7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/usr/bin/perl

use strict;
use warnings;

my $exit_code = 0;
sub report {
	my ($target, $msg) = @_;
	print STDERR "error: $target: $msg\n";
	$exit_code = 1;
}

local $/;
while (my $slurp = <>) {
	report($ARGV, "has no 'Part of the linkgit:git[1] suite' end blurb")
		unless $slurp =~ m[
		^GIT\n
		 ---\n
		\QPart of the linkgit:git[1] suite\E \n
		\z
	]mx;
}

exit $exit_code;