138 lines
2.7 KiB
TOML
138 lines
2.7 KiB
TOML
exclude = [
|
|
"target",
|
|
"tests/lib/**/*",
|
|
]
|
|
|
|
[commands.clippy]
|
|
type = "lint"
|
|
include = "**/*.rs"
|
|
invoke = "once"
|
|
path-args = "none"
|
|
working-dir.chdir-to = "run-tests"
|
|
cmd = [
|
|
"cargo",
|
|
"clippy",
|
|
"--color",
|
|
"always",
|
|
"--locked",
|
|
"--all-targets",
|
|
"--all-features",
|
|
"--",
|
|
"-D",
|
|
"clippy::pedantic",
|
|
]
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 101
|
|
expect_stderr = true
|
|
labels = ["default"]
|
|
|
|
[commands."clippy --fix"]
|
|
type = "tidy"
|
|
include = "**/*.rs"
|
|
invoke = "once"
|
|
path-args = "none"
|
|
working-dir.chdir-to = "run-tests"
|
|
cmd = [
|
|
"cargo",
|
|
"clippy",
|
|
"--fix",
|
|
"--allow-dirty",
|
|
"--locked",
|
|
"--all-targets",
|
|
"--all-features",
|
|
"--",
|
|
"-D",
|
|
"clippy::pedantic",
|
|
]
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 101
|
|
expect_stderr = true
|
|
labels = ["default"]
|
|
|
|
[commands.rustfmt]
|
|
type = "both"
|
|
include = "**/*.rs"
|
|
working-dir.chdir-to = "run-tests"
|
|
cmd = ["rustfmt", "--edition", "2021"]
|
|
lint_flags = "--check"
|
|
ok_exit_codes = [0]
|
|
lint_failure_exit_codes = [1]
|
|
labels = ["default", "fast-tidy"]
|
|
|
|
[commands."ruff for linting"]
|
|
type = "both"
|
|
include = [ "**/*.py" ]
|
|
cmd = "ruff"
|
|
lint_flags = [ "check" ]
|
|
tidy_flags = [ "check", "--fix" ]
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
|
|
[commands."ruff for tidying"]
|
|
type = "both"
|
|
include = [ "**/*.py" ]
|
|
cmd = "ruff"
|
|
lint_flags = [ "format", "--check" ]
|
|
tidy_flags = [ "format" ]
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
|
|
[commands.typos]
|
|
type = "both"
|
|
include = "**/*"
|
|
exclude = "**/*.tar.gz"
|
|
invoke = "once"
|
|
cmd = "typos"
|
|
tidy_flags = "--write-changes"
|
|
ok-exit-codes = 0
|
|
lint-failure-exit-codes = 2
|
|
|
|
[commands.prettier-md]
|
|
type = "both"
|
|
include = [ "**/*.md" ]
|
|
cmd = [ "prettier", "--no-config", "--print-width", "100", "--prose-wrap", "always" ]
|
|
lint_flags = "--check"
|
|
tidy_flags = "--write"
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
ignore_stderr = [ "Code style issues" ]
|
|
|
|
[commands.prettier-yml]
|
|
type = "both"
|
|
include = [ "**/*.yml" ]
|
|
cmd = [ "prettier", "--no-config" ]
|
|
lint_flags = "--check"
|
|
tidy_flags = "--write"
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
ignore_stderr = [ "Code style issues" ]
|
|
|
|
[commands.omegasort-gitignore]
|
|
type = "both"
|
|
include = "**/.gitignore"
|
|
cmd = [ "omegasort", "--sort", "path", "--unique" ]
|
|
lint_flags = "--check"
|
|
tidy_flags = "--in-place"
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
ignore_stderr = [
|
|
"The .+ file is not sorted",
|
|
"The .+ file is not unique",
|
|
]
|
|
|
|
[commands.shellcheck]
|
|
type = "lint"
|
|
include = "**/*.sh"
|
|
cmd = "shellcheck"
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|
|
|
|
[commands.shfmt]
|
|
type = "both"
|
|
include = "**/*.sh"
|
|
cmd = ["shfmt", "--simplify", "--indent", "4"]
|
|
lint_flags = "--diff"
|
|
tidy_flags = "--write"
|
|
ok_exit_codes = 0
|
|
lint_failure_exit_codes = 1
|