spaces before tabs
Bjoern A. Zeeb
bzeeb-lists at lists.zabbadoz.net
Mon Mar 15 10:50:11 PST 2004
On Mon, 15 Mar 2004, Colin Percival wrote:
> At 16:28 15/03/2004, David O'Brien wrote:
> >Please no!
> >
> >Not another round of:
> >
> > ----------------------------
> > date: 1995/05/30 06:29:28; author: rgrimes; state: Exp; lines: +3 -3
> > Remove trailing whitespace.
> > ----------------------------
> >
> >which touches thousands of files.
>
> Well, I was looking at *leading* whitespace, not *trailing* whitespace...
>
> Ok, I'll find something else to play with. :-)
perhaps put the patch on the web along with a list of files affected
so that people who work on that file can also incorporate the
changes.
Only by looking at /usr/src/sys/ I can find ~3500 "ignorant" files
with some quick-and-dirty-sh-inline-perl-hack
(including some false positives from txt files and quoted strings).
The follwing numbers are number of "ignorant" lines (one line may
"violate" multiple policies):
# Do not add whitespace at the end of a line (/\s\n$/)
bz at noc:/usr/src/HEAD> grep ^1: style-9-check.out | wc -l
48370
# do not use more spaces than a tab will produce (/\ {8,}/)
# assuming ts=8
bz at noc:/usr/src/HEAD> grep ^2: style-9-check.out | wc -l
69900 (33444 with sys/contrib/dev/acpica excluded)
# do not use spaces in front of tabs (/\ \t/)
bz at noc:/usr/src/HEAD> grep ^3: style-9-check.out | wc -l
14107
# check for non-\n line breaks (/(\r|\r\n)$/)
bz at noc:/usr/src/HEAD> grep ^r: style-9-check.out | wc -l
903
If you have a well written script to find them please make it
available and let people check sources before committing like
portlint is used for ports.
--
Greetings
Bjoern A. Zeeb bzeeb at Zabbadoz dot NeT
56 69 73 69 74 http://www.zabbadoz.net/
More information about the freebsd-current
mailing list