-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.toml
76 lines (63 loc) · 1.66 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
extend = [
{ path = "schema.Makefile.toml" },
{ path = "coverage_grcov.Makefile.toml" }
]
[config]
default_to_workspace = false
[env]
# Directory with wasm files used by integration tests (another directory can be used instead, for example 'artifacts' from rust-optimizer)
ARTIFACTS_DIR_PATH = "artifacts"
[tasks.build]
toolchain = "stable"
command = "cargo"
args = ["build", "--release", "--target", "wasm32-unknown-unknown", "--locked"]
[tasks.rust-optimizer]
script = """
if [[ $(arch) == "arm64" ]]; then
image="cosmwasm/workspace-optimizer-arm64:0.12.13"
else
image="cosmwasm/workspace-optimizer:0.12.13"
fi
docker run --rm -v "$(pwd)":/code \
--mount type=volume,source="$(basename "$(pwd)")_cache",target=/code/target \
--mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \
${image}
"""
[tasks.test]
toolchain = "stable"
command = "cargo"
args = ["test", "--locked"]
[tasks.unit-test]
toolchain = "stable"
command = "cargo"
args = ["test", "--locked", "--workspace", "--exclude", "mars-integration-tests"]
[tasks.integration-test]
toolchain = "stable"
command = "cargo"
args = ["test", "--locked", "--package", "mars-integration-tests"]
[tasks.fmt]
toolchain = "nightly"
command = "cargo"
args = ["fmt", "--all", "--check"]
[tasks.clippy]
toolchain = "stable"
command = "cargo"
args = ["clippy", "--tests", "--", "-D", "warnings"]
[tasks.audit]
toolchain = "stable"
command = "cargo"
args = ["audit"]
[tasks.coverage-html]
alias = "coverage-grcov-html"
[tasks.coverage-lcov]
alias = "coverage-grcov-lcov"
[tasks.all-actions]
dependencies = [
"fmt",
"clippy",
"build",
"test",
"audit",
"generate-all-schemas",
"rust-optimizer",
]