Re: [PATCH] checkpatch: warn if changed lines exceeds a maximum size
From: Brown, Nicholas
Date: Tue Jan 30 2018 - 15:25:50 EST
On Tue, 2018-01-30 at 11:09 -0800, Joe Perches wrote:
> On Tue, 2018-01-30 at 19:01 +0000, Nicholas Brown wrote:
> > Changed lines is the total of inserted and deleted lines.
> > By default there is no limit, --max-changed-lines may be used to
> > set a
> > value. Some users may wish to encourage that patches are split into
> > smaller parts using this.
> > See Documentation/process/submitting-patches.rst#split-changes
>
> Still whitespace damaged.
> Indentations use tabs not 2 spaces.
Hopefully editor set correctly now, so follow-up should fix this.
>
> and another issue below
>
> >
> > @@ -2233,6 +2239,14 @@ sub process {
> >
> > push(@fixed, $rawline) if ($fix);
> >
> > + if ($rawline=~/^\+/) {
> > + $inserted_lines_total++
>
> This counts patch header blocks with \+\+\+
Good catch. Will fix.
>
> > + }
> > +
> > + if ($rawline=~/^-/) {
> > + $deleted_lines_total++
> > + }
>
> and \-\-\-
Ditto.
Thanks, Nick