-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
53 lines (40 loc) · 1.33 KB
/
Makefile
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
check:
cargo check
test:
cargo test
doc:
cargo doc
cp ./build/vendored-docs-redirect.index.html target/doc/index.html
bench:
cargo bench
# Lints with everything we have in our CI arsenal
lint-all: audit lint-fmt clippy license spellcheck
audit:
cargo audit || (echo "See .config/audit.toml"; false)
lint-fmt:
cargo fmt --all --check
taplo fmt --check
taplo lint
corepack enable && yarn && yarn md-check
fmt:
cargo fmt --all
taplo fmt
corepack enable && yarn && yarn md-fmt
clippy:
cargo clippy --all-targets --quiet --no-deps -- --deny=warnings
cargo clippy --all-targets --no-default-features --quiet --no-deps -- --deny=warnings
cargo clippy --all-targets --all-features --quiet --no-deps -- --deny=warnings
# Checks if all headers are present and adds if not
license:
./scripts/add_license.sh
spellcheck:
cargo spellcheck --code 1 || (echo "See .config/spellcheck.md for tips"; false)
install-lint-tools:
cargo install --locked taplo-cli
cargo install --locked cargo-audit
cargo install --locked cargo-spellcheck
install-lint-tools-ci:
wget https://github.com/cargo-bins/cargo-binstall/releases/latest/download/cargo-binstall-x86_64-unknown-linux-musl.tgz
tar xzf cargo-binstall-x86_64-unknown-linux-musl.tgz
cp cargo-binstall ~/.cargo/bin/cargo-binstall
cargo binstall --no-confirm taplo-cli cargo-spellcheck cargo-audit