-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile.toml
More file actions
131 lines (116 loc) · 2.71 KB
/
Makefile.toml
File metadata and controls
131 lines (116 loc) · 2.71 KB
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
[config]
default_to_workspace = false
[env]
CARGO_MAKE_CLIPPY_ARGS = "-- --no-deps"
CARGO_MAKE_COVERAGE_PROVIDER = "llvm-cov"
CARGO_MAKE_CARGO_BUILD_TEST_FLAGS = ""
# This is the directory where we generate the CLI's reference
# documentation.
CLI_REFERENCE_DIR = "target/debug/"
# This is the name of the file containing the CLI's reference
# documentation.
CLI_REFERENCE_FILE_NAME = "reference.md"
[env.development]
CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true
[tasks.dev-test-flow]
dependencies = [
"pre-build",
"format-flow",
"clippy-flow",
"build",
"post-build",
"pre-docs",
"docs",
"post-docs",
"test-flow",
]
[tasks.pre-build]
dependencies = ["format-toml-conditioned-flow", "unused-dependencies-flow"]
[tasks.ci-flow]
dependencies = [
"pre-ci-flow",
"print-env-flow",
"pre-build",
"check-format-flow",
"clippy-flow",
"build",
"post-build",
"pre-docs",
"docs",
"post-docs",
"test-flow",
"coverage-flow",
"post-ci-flow",
]
[tasks.test]
workspace = true
description = "Run our test suite (excluding snapshot tests)"
command = "cargo"
args = [
"nextest",
"run",
"--locked",
"-E",
"not binary(snapshot_tests)",
"@@remove-empty(CARGO_MAKE_CARGO_VERBOSE_FLAGS)",
"@@split(CARGO_MAKE_CARGO_BUILD_TEST_FLAGS, )",
]
[tasks.test-snapshot]
description = "Run snapshot tests single-threaded for deterministic results"
command = "cargo"
args = [
"nextest",
"run",
"--locked",
"--test",
"snapshot_tests",
"-j",
"1",
"@@remove-empty(CARGO_MAKE_CARGO_VERBOSE_FLAGS)",
"@@split(CARGO_MAKE_CARGO_BUILD_TEST_FLAGS, )",
]
[tasks.test-flow]
dependencies = ["test", "test-snapshot"]
[tasks.help]
command = "cargo"
description = "List help text for wack executable"
category = "Development"
args = [
"run",
"@@remove-empty(CARGO_MAKE_CARGO_VERBOSE_FLAGS)",
"@@split(CARGO_MAKE_CARGO_BUILD_TEST_FLAGS, )",
"--",
"--help",
]
[tasks.outdated]
workspace = true
description = "List dependencies with newer released versions"
args = ["outdated", "--root-deps-only", "--exit-code", "1"]
[tasks.fmt]
workspace = true
alias = "format"
[tasks.check-format]
workspace = true
[tasks.wc]
description = "Calculate the LoC in src."
category = "Development"
command = "tokei"
args = ["."]
[tasks.gen-cli-reference]
description = "Generate the CLI's reference documentation in Markdown format"
category = "Development"
script_runner = "@shell"
script = '''
mkdir -p $CLI_REFERENCE_DIR || true
cargo run --bin mkdown-docs --features=markdown > $CLI_REFERENCE_DIR/$CLI_REFERENCE_FILE_NAME
'''
[tasks.bacon]
description = "Watch tests and rerun on file change."
category = "Development"
command = "bacon"
args = [
"nextest",
"--",
"--workspace",
"@@split(CARGO_MAKE_CARGO_BUILD_TEST_FLAGS, )",
]