Skip to content

Commit eab00b3

Browse files
authored
badwords: re-sync with curl, fix fallouts (#510)
1 parent a4cad7b commit eab00b3

File tree

4 files changed

+54
-39
lines changed

4 files changed

+54
-39
lines changed

.github/scripts/badwords.pl

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,12 @@
2020
my @whitelist;
2121
my %alt;
2222
my %exactcase;
23+
my $skip_indented = 1;
2324

25+
if($ARGV[0] eq "-a") {
26+
shift @ARGV;
27+
$skip_indented = 0;
28+
}
2429
my %wl;
2530
if($ARGV[0] eq "-w") {
2631
shift @ARGV;
@@ -68,7 +73,7 @@ sub file {
6873
my $in = $_;
6974
$l++;
7075
chomp $in;
71-
if($in =~ /^ /) {
76+
if($skip_indented && $in =~ /^ /) {
7277
next;
7378
}
7479
# remove the link part
@@ -94,7 +99,7 @@ sub file {
9499
}
95100

96101
print STDERR "$f:$l:$c: error: found bad word \"$w\"\n";
97-
printf STDERR " %4d | $in\n", $l;
102+
printf STDERR " %4d | %s\n", $l, $in;
98103
printf STDERR " | %*s^%s\n", length($p), " ",
99104
"~" x (length($w)-1);
100105
printf STDERR " maybe use \"%s\" instead?\n", $alt{$w};

.github/scripts/badwords.txt

Lines changed: 41 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -10,59 +10,69 @@ tool chain:toolchain
1010
tool-chain:toolchain
1111
wild-card:wildcard
1212
wild card:wildcard
13+
\bit's:it is
14+
aren't:are not
15+
can't:cannot
16+
could've:could have
17+
couldn't:could not
18+
didn't:did not
19+
doesn't:does not
20+
don't=do not
21+
haven't:have not
22+
i'd:I would
23+
i'll:I will
1324
i'm:I am
14-
you've:You have
15-
we've:we have
16-
we're:we are
17-
we'll:we will
18-
we'd:we would
19-
they've:They have
20-
they're:They are
21-
they'll:They will
25+
i've:I have
26+
isn't:is not
27+
it'd:it would
28+
it'll:it will
29+
might've:might have
30+
needn't:need not
31+
should've:should have
32+
shouldn't:should not
33+
that's:that is
34+
there's:there is
2235
they'd:They would
23-
you've:you have
36+
they'll:They will
37+
they're:They are
38+
they've:They have
39+
this'll:this will
40+
wasn't:was not
41+
we'd:we would
42+
we'll:we will
43+
we're:we are
44+
we've:we have
45+
weren't:were not
46+
won't:will not
47+
would've:would have
48+
wouldn't:would not
2449
you'd:you would
2550
you'll:you will
2651
you're:you are
27-
should've:should have
28-
don't=do not
29-
could've:could have
30-
doesn't:does not
31-
isn't:is not
32-
aren't:are not
52+
you've:you have
3353
a html: an html
3454
a http: an http
3555
a ftp: an ftp
3656
a IPv4: an IPv4
3757
a IPv6: an IPv6
38-
url =URL
58+
url [^=]=URL
3959
[^/]internet\b=Internet
4060
isation:ization
41-
\bit's:it is
42-
it'd:it would
43-
there's:there is
4461
[^.]\. And: Rewrite it somehow?
4562
^(And|So|But) = Rewrite it somehow?
4663
\. But: Rewrite it somehow?
4764
\. So : Rewrite without "so" ?
48-
dir :directory
65+
dir [^=]=directory
66+
Dir [^=]=Directory
4967
sub-director:subdirector
50-
you'd:you would
51-
you'll:you will
52-
can't:cannot
53-
that's:that is
5468
web page:webpage
5569
host name\b:hostname
5670
host names\b:hostnames
57-
[^;]file name\b:filename
71+
[^;<]file name\b:filename
5872
file names\b:filenames
5973
\buser name\b:username
6074
\buser names\b:usernames
6175
\bpass phrase:passphrase
62-
didn't:did not
63-
doesn't:does not
64-
won't:will not
65-
couldn't:could not
6676
\bwill\b:rewrite to present tense
6777
\b32bit=32-bit
6878
\b64bit=64-bit
@@ -78,5 +88,5 @@ couldn't:could not
7888
---WWW::Curl
7989
---NET::Curl
8090
---Curl Corporation
81-
\bmanpages[^./&:-]:man pages
82-
\bmanpage[^si./&:-]:man page
91+
\bmanpages[^./;=&{:-]:man pages
92+
\bmanpage[^si./;=&{:-]:man page

_changes.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16825,7 +16825,7 @@
1682516825
THISBOX(2.7)
1682616826
<p> Changes:
1682716827
<ul class="changes">
16828-
CHG Removed the -l option and introduced the -f option instead. Now I'll
16828+
CHG Removed the -l option and introduced the -f option instead. Now I
1682916829
rewrite the former -l kludge in an external script that uses urlget to
1683016830
fetch multipart files like that.
1683116831
CHG '-f' is introduced, it means Fail without output in case of HTTP server

docs/survey/_2014.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -104,10 +104,10 @@
104104
<p>
105105
<img align="left" src="charts/chart_003.png">
106106
<pre>
107-
I've filed bug report(s) 47 25%
108-
I've sent patch(es) 56 29%
109-
I've responded to questions on mailing list / forums 43 23%
110-
I've helped out in other ways 38 20%
107+
I have filed bug report(s) 47 25%
108+
I have sent patch(es) 56 29%
109+
I have responded to questions on mailing list / forums 43 23%
110+
I have helped out in other ways 38 20%
111111
I run tests or provide infrastructure 7 4%
112112
</pre>
113113
</div>
@@ -281,7 +281,7 @@
281281

282282
<div style="clear:left;">
283283
SUBTITLE(If you miss support for any protocol tell us which!)
284-
<p> Since this was a plain text field, I've parsed and edited the responses
284+
<p> Since this was a plain text field, I have parsed and edited the responses
285285
and then counted the number of times the same one occurred. Only a small
286286
portion of the participants filled in this field.
287287

0 commit comments

Comments
 (0)