[Linux-kernel-mentees] [PATCH RFC v3 2/3] docs: add documentation for checkpatch

Joe Perches joe at perches.com
Mon Feb 15 18:11:03 UTC 2021


On Sun, 2021-02-14 at 12:15 +0000, Matthew Wilcox wrote:
> On Sat, Feb 13, 2021 at 06:45:12PM +0530, Dwaipayan Ray wrote:
> > +Checkpatch (scripts/checkpatch.pl) is a perl script which checks for trivial style
> 
> It's quite amusing that this patch contains lines > 80 columns.

Then you could amuse yourself further by looking at the existing
line lengths of .rst files.

$ git ls-files -- '*.rst' | \
  xargs cat | \
  awk '{print length($0);}' | \
  sort -n | \
  uniq -c | \
  tail -20
      2 226
      1 230
      1 233
      1 234
     48 246
      1 253
      2 257
      1 263
      1 270
      1 275
      1 276
      1 293
      1 294
      1 308
      2 324
      1 359
      1 360
      5 369
      1 370
      2 409

Other than testing whether or not an SPDX license line exists,
checkpatch doesn't inspect .rst files.

There are better tools for that.




More information about the Linux-kernel-mentees mailing list