-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile.toml
76 lines (63 loc) · 1.69 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
[env]
RUST_BACKTRACE = "1"
[tasks.install-nightly]
script = '''
if [ -z "$(rustup toolchain list | grep 'nightly')" ];
then
rustup toolchain install nightly --component rustfmt
else
echo "nightly is already installed."
fi
'''
[tasks.install-nightly.windows]
command = "rustup"
args = ["toolchain", "install", "nightly", "--component", "rustfmt"]
[tasks.install-fmt]
command = "rustup"
args = ["component", "add", "rustfmt", "--toolchain", "nightly"]
dependencies = ["install-nightly"]
[tasks.fmt]
toolchain = "nightly"
command = "cargo"
args = ["fmt"]
dependencies = ["install-fmt"]
[tasks.doctest-slow]
command = "cargo"
args = ["--locked", "test", "--all-features", "--jobs", "1", "--doc", "--", "--quiet"]
[tasks.doctest]
command = "cargo"
args = ["--locked", "test", "--all-features", "--doc", "--", "--quiet"]
[tasks.test]
command = "cargo"
args = ["--locked", "test", "--all-features", "--tests", "--", "--quiet"]
dependencies = ["doctest"]
[tasks.tdd]
install_crate = "cargo-watch"
command = "cargo"
args = [ "watch"
, "--watch", "./src"
, "--watch", "./tests"
, "--delay", "0"
, "-x", "make -t test"
]
[tasks.cdd] # "compile" driven development?
install_crate = "cargo-watch"
command = "cargo"
args = [ "watch"
, "--watch", "./src"
, "--watch", "./tests"
, "-x", "check --all-features"
, "-x", "make fmt"
]
[tasks.check-fmt]
toolchain = "nightly"
command = "cargo"
args = ["fmt", "--", "--check"]
dependencies = ["install-fmt"]
[tasks.check-clippy]
command = "cargo"
args = ["clippy"]
[tasks.ci]
dependencies = ["test", "check-fmt", "check-clippy"]
[tasks.update-readme]
script = "cargo install cargo-readme && cargo readme > README.md"