generated from okp4/template-oss
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.toml
96 lines (75 loc) · 2.68 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
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
[tasks.format-rust]
args = ["fmt"]
command = "cargo"
description = "Format rust sources files."
install_crate = { rustup_component_name = "rustfmt" }
[tasks.lint-rust-format]
args = ["fmt", "--all", "--", "--check"]
command = "cargo"
description = "Check format of sources files."
install_crate = { rustup_component_name = "rustfmt" }
[tasks.lint-rust]
args = ["cranky"]
command = "cargo"
dependencies = ["install-clippy"]
description = "Check lint of all sources files."
[tasks.lint-toml]
args = ["lint"]
command = "taplo"
dependencies = ["install-taplo-cli"]
description = "Check lint of all toml files."
[tasks.lint-cargo-toml]
args = ["Cargo.toml"]
command = "cargo-toml-lint"
dependencies = ["install-cargo-toml-lint"]
description = "Check lint of cargo toml files."
[tasks.format-toml]
args = ["fmt"]
command = "taplo"
dependencies = ["install-taplo-cli"]
description = "Format toml file"
[tasks.lint]
dependencies = ["lint-rust-format", "lint-rust", "lint-toml", "lint-cargo-toml"]
[tasks.format]
dependencies = ["format-rust", "format-toml"]
[tasks.clean]
args = ["clean"]
command = "cargo"
[tasks.build]
args = ["build", "--release", "--locked"]
command = "cargo"
[tasks.build-coverage]
args = ["build"]
command = "cargo"
description = "Compile the source code and create testable artifacts."
env = { RUSTFLAGS = "-Cinstrument-coverage" }
[tasks.test]
args = ["test", "--tests", "--workspace", "--locked", "--all-features"]
command = "cargo"
dependencies = ["build-coverage", "install-llvm-tools-preview"]
description = "Run all unit tests."
env = { LLVM_PROFILE_FILE = "default_%p.profraw", RUST_BACKTRACE = 1, RUSTFLAGS = "-Cinstrument-coverage" }
[tasks.test-coverage]
args = ["llvm-cov", "--workspace", "--lcov", "--output-path", "lcov.info"]
command = "cargo"
dependencies = ["install-llvm-tools-preview", "install-llvm-cov"]
[tasks.install-llvm-tools-preview]
install_crate = { rustup_component_name = "llvm-tools-preview" }
[tasks.install-llvm-cov]
install_crate = { crate_name = "cargo-llvm-cov", min_version = "0.5.31" }
[tasks.install-clippy]
install_crate = { rustup_component_name = "clippy", min_version = "0.1.72" }
[tasks.intall-cranky]
dependencies = ["install-clippy"]
install_crate = { crate_name = "cargo-cranky", min_version = "0.3.0" }
[tasks.install-taplo-cli]
install_crate = { crate_name = "taplo-cli", binary = "taplo", test_arg = "--help", min_version = "0.8.1" }
[tasks.install-cargo-toml-lint]
install_crate = { crate_name = "cargo-toml-lint", binary = "cargo-toml-lint", test_arg = "--help", min_version = "0.1.1" }
[tasks.publish]
args = ["publish", "--token", "${CARGO_API_TOKEN}"]
command = "cargo"
[config]
min_version = "0.36.13"
[env]
CARGO_MAKE_CRATE_INSTALLATION_LOCKED = true