Lines Matching refs:line
14 # Keywords allowed before the colon on the first line of a commit message:
33 # a commented diagnostic "# $ERR" line at the top.
59 my ($line) = @_;
61 $line =~ /^[Vv]ersion \d/
64 $line =~ /:/
65 or return 'missing colon on first line of log message';
67 $line =~ /\.$/
68 and return 'do not use a period "." at the end of the first line';
70 # The token(s) before the colon on the first line must be on our list
72 (my $pre_colon = $line) =~ s/:.*//;
76 and return 'invalid first word(s) of summary line: ' . join (', ', @bad);
95 my @line = @$line_ref;
96 chomp @line;
103 # while (@line && $line[0] =~ /^(?:#.*|[ \t]*)$/) { shift @line; }
106 # while (@line && $line[$#line] =~ /^(?:#.*|[ \t]*)$/) { pop @line; }
108 @line == 0
111 my $bad = bad_first_line $line[0];
115 # Second line should be blank or not present.
116 2 <= @line && length $line[1]
117 and return 'second line must be empty';
119 # Limit line length to allow for the ChangeLog's leading TAB.
121 foreach my $line (@line)
123 last if $line =~ '.*-{24} >8 -{24}$';
124 my $len = length $line;
125 $max_len < $len && $line =~ /^[^#]/
126 and return "line length ($len) greater than than max: $max_len";
129 my $buf = join ("\n", @line) . "\n";
150 my @line;
151 my $err = check_msg $log_file, \@line;
157 # Insert the diagnostic as a comment on the first line of $log_file.
158 rewrite $log_file, $err, \@line;