97 lines
3.3 KiB
TOML
97 lines
3.3 KiB
TOML
# Config for the `typos` crate, used by `./x test tidy --extra-checks=spellcheck`.
|
|
# See also: https://github.com/crate-ci/typos/blob/v1.28.2/docs/reference.md
|
|
|
|
[files]
|
|
extend-exclude = [
|
|
# exclude git (sub)modules and generated content
|
|
"compiler/rustc_baked_icu_data",
|
|
"compiler/rustc_codegen_cranelift",
|
|
"compiler/rustc_codegen_gcc",
|
|
"library/backtrace",
|
|
"library/compiler-builtins",
|
|
"library/stdarch",
|
|
# generated lorem ipsum texts
|
|
"library/alloctests/benches/str.rs",
|
|
"library/alloctests/tests/str.rs",
|
|
]
|
|
|
|
[default.extend-words]
|
|
# Allowlist for words that look like typos but are not, or aren't worth fixing
|
|
# right now. Entries should look like `mipsel = "mipsel"`.
|
|
#
|
|
# tidy-alphabetical-start
|
|
arange = "arange"
|
|
childs = "childs"
|
|
clonable = "clonable"
|
|
filetimes = "filetimes"
|
|
leafs = "leafs"
|
|
makro = "makro"
|
|
misformed = "misformed"
|
|
moreso = "moreso"
|
|
numer = "numer"
|
|
optin = "optin"
|
|
publically = "publically"
|
|
rplace = "rplace"
|
|
splitted = "splitted"
|
|
taits = "taits"
|
|
targetting = "targetting"
|
|
unparseable = "unparseable"
|
|
unstability = "unstability"
|
|
unstalled = "unstalled"
|
|
# tidy-alphabetical-end
|
|
|
|
# Denylist to forbid misspelled words that aren't detected by the built-in
|
|
# dictionary. Entries should look like `mipsel = ""` or `mipsel = "misspell"`;
|
|
# the non-empty form can be automatically fixed by `--bless`.
|
|
#
|
|
# tidy-alphabetical-start
|
|
# tidy-alphabetical-end
|
|
|
|
[default.extend-identifiers]
|
|
# Allowlist for specific identifiers that should be permitted even though they
|
|
# appear to contain typos that would be forbidden in other identifiers.
|
|
#
|
|
# For example, you might want to allow a specific constant like
|
|
# `DNS_ERROR_INVAILD_VIRTUALIZATION_INSTANCE_NAME`, but still want to forbid
|
|
# the typo `INVAILD` in other places.
|
|
#
|
|
# tidy-alphabetical-start
|
|
DNS_ERROR_INVAILD_VIRTUALIZATION_INSTANCE_NAME = "DNS_ERROR_INVAILD_VIRTUALIZATION_INSTANCE_NAME"
|
|
ERRNO_ACCES = "ERRNO_ACCES"
|
|
ERROR_DS_FILTER_USES_CONTRUCTED_ATTRS = "ERROR_DS_FILTER_USES_CONTRUCTED_ATTRS"
|
|
ERROR_DS_NOT_AUTHORITIVE_FOR_DST_NC = "ERROR_DS_NOT_AUTHORITIVE_FOR_DST_NC"
|
|
ERROR_FILENAME_EXCED_RANGE = "ERROR_FILENAME_EXCED_RANGE"
|
|
ERROR_MCA_OCCURED = "ERROR_MCA_OCCURED"
|
|
ERROR_REQ_NOT_ACCEP = "ERROR_REQ_NOT_ACCEP"
|
|
EnzymeTypeTreeShiftIndiciesEq = "EnzymeTypeTreeShiftIndiciesEq"
|
|
EnzymeTypeTreeShiftIndiciesEqFn = "EnzymeTypeTreeShiftIndiciesEqFn"
|
|
Oppen = "Oppen"
|
|
# typos treats this as two different camelcase words (`SETTIN` and `Gs`)
|
|
# Tracked in: https://github.com/crate-ci/typos/issues/745
|
|
SETTINGs = "SETTINGs"
|
|
debug_aranges = "debug_aranges"
|
|
key_smove = "key_smove" # shifted move key, used by terminfo
|
|
shift_indicies_eq = "shift_indicies_eq"
|
|
tolen = "tolen"
|
|
# tidy-alphabetical-end
|
|
|
|
[default]
|
|
extend-ignore-words-re = [
|
|
# words with length <= 4 chars is likely noise
|
|
"^[a-zA-Z]{1,4}$",
|
|
]
|
|
|
|
extend-ignore-re = [
|
|
# allow turning off spell checking
|
|
"(?s)(#|//)\\s*spellchecker:off.*?\\n\\s*(#|//)\\s*spellchecker:on",
|
|
# ignore these intentional typo examples
|
|
"/// 1 \\| #\\[cfg\\(widnows\\)\\]",
|
|
"/// warning: unexpected `cfg` condition name: `widnows`",
|
|
"/// #\\[cfg\\(widnows\\)\\]",
|
|
"\\.arg\\(\"Oh no, a tpyo!\"\\)",
|
|
# string used in benches
|
|
"\"core::iter::adapters::Copie\"",
|
|
"-Ccontrol-flow-guard",
|
|
"concat!\\(\"CURRENT_RUSTC_VERSIO\", \"N\"\\)",
|
|
"\\*\\*v\\*\\*ariable",
|
|
]
|