Skip to content

Commit 6704551

Browse files
committed
Suggest writing out numbers
1 parent b362e3a commit 6704551

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/actions/spelling/line_forbidden.patterns

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,18 @@
3636
# Complete sentences in parentheticals should not have a space before the period.
3737
\s\.\)(?!.*\}\})
3838

39+
# Write out small numbers (unless they are code)
40+
# See https://www.scribendi.com/academy/articles/when_to_spell_out_numbers_in_writing.en.html#:~:text=Writing%20Small%20and%20Large%20Numbers,ten%29%20are%20written%20as%20numerals%2e
41+
\s[1-9] [a-z]+ [a-z]+\s
42+
43+
# Write out numbers at the start of a sentence
44+
# https://www.scribendi.com/academy/articles/when_to_spell_out_numbers_in_writing.en.html#:~:text=Beginning%20a%20Sentence%20with%20a%20Number,may%20be%2e
45+
(?:[a-z]{4,}|\s(?:[a-eg-z][a-z]{2}|f[a-hj-z][a-z]|fi[a-fh][a-z]))[:.?!] [1-9] [a-z]{3,} [a-z]+\s\w+
46+
47+
# Don't write two numbers in a row
48+
# https://www.scribendi.com/academy/articles/when_to_spell_out_numbers_in_writing.en.html#:~:text=Paired%20Numbers%20%28Two%20Numbers%20in,librarian%20to%20begin%20story%20time%2e
49+
(?:[a-z]{4,}|\s(?!apr|aug|dec|feb|fri|jan|mar|mon|nov|oct|sat|sep|sun|thu|tue|wed)[a-z]{3})\s\d+\s\d+(?!--)[-\s](?:(?!--)[-A-Za-z]){2,}\s
50+
3951
# This probably indicates Mojibake https://en.wikipedia.org/wiki/Mojibake
4052
# You probably should try to unbake this content
4153
Ã(?:Â[¤¶¥]|[£¢])|Ã

0 commit comments

Comments
 (0)