-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
50 lines (41 loc) · 949 Bytes
/
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
.PHONY: build
build:
cargo build --release
.PHONY: check
check:
cargo check
$(MAKE) test
cargo clippy
$(MAKE) clippy_float_cast
cargo fmt --check
.PHONY: test
test:
cargo test --lib
.PHONY: clippy_float_cast
clippy_float_cast:
cargo clippy -- \
-W clippy::cast-possible-truncation \
-W clippy::cast-sign-loss
.PHONY: clippy_nursery
clippy_nursery:
cargo clippy -- -W clippy::nursery
.PHONY: clippy_cargo
clippy_cargo:
cargo clippy -- -W clippy::cargo
.PHONY: clippy_pedantic
clippy_pedantic:
cargo clippy -- \
-W clippy::pedantic \
-A clippy::single_match_else \
-A clippy::uninlined-format-args \
-A clippy::missing_errors_doc
# XXX Coverage recipes assume llvm-cov is installed:
.PHONY: coverage
coverage:
cargo llvm-cov --lib --ignore-filename-regex 'tests\.rs'
.PHONY: coverage_html
coverage_html:
cargo llvm-cov --lib --ignore-filename-regex 'tests\.rs' --open
.PHONY: install
install:
cargo install --path .