-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile.toml
66 lines (57 loc) · 1.55 KB
/
Makefile.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
[config]
default_to_workspace = false
[tasks.ci-flow]
dependencies = ["test-doc", "clippy", "test", "docs"]
[tasks.check]
command = "cargo"
args = ["check", "--all-features", "--all-targets"]
[tasks.test]
command = "cargo"
args = ["nextest", "run"]
[tasks.test-doc]
command = "cargo"
args = ["test", "--doc"]
[tasks.pre-docs]
script = '''
cargo run --bin snippetter
TARGET_DOC_PATH="target/doc"
if [ ! -e "${TARGET_DOC_PATH}" ]; then
mkdir "${TARGET_DOC_PATH}"
fi
cp contents/* ${TARGET_DOC_PATH}
'''
[tasks.docs]
env = { RUSTDOCFLAGS = "--html-in-header contents/header.html" }
command = "cargo"
args = ["doc", "--workspace", "--no-deps"]
dependencies = ["pre-docs"]
[tasks.clippy]
command = "cargo"
args = [
"clippy",
"--all-features",
"--all-targets",
"--",
"-Dwarnings",
"-Wclippy::pedantic",
"-Aclippy::cast-possible-truncation",
"-Aclippy::cast-possible-wrap",
"-Aclippy::cast-precision-loss",
"-Aclippy::cast-sign-loss",
"-Aclippy::doc-markdown",
"-Aclippy::manual-let-else",
"-Aclippy::maybe-infinite-iter",
"-Aclippy::missing-errors-doc",
"-Aclippy::missing-panics-doc",
"-Aclippy::module-name-repetitions",
"-Aclippy::must-use-candidate",
"-Aclippy::return-self-not-must-use",
"-Aclippy::semicolon-if-nothing-returned",
"-Aclippy::similar-names",
"-Aclippy::uninlined-format-args",
"-Aclippy::unreadable_literal",
]
[tasks.pedantics]
script = '''
cargo clippy --all-targets --all-features -- -W clippy::pedantic 2>&1 | grep 'note: `-W clippy::' | sed -n 's/.*note: `-W clippy::\([a-z|-]*\).*/\1/p' | sort | uniq
'''