-
Notifications
You must be signed in to change notification settings - Fork 9
/
Makefile
53 lines (42 loc) · 1.18 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
.phony: all test
all:
cargo fmt
cargo build
cargo clippy --all-targets --all-features -- -D warnings
cargo build --examples
test:
cargo test
clean:
cargo clean
riscv:
cargo build --target riscv32imac-unknown-none-elf
check-for-todos:
@git grep -n -i -e todo -e fixme -- \
:^Makefile \
:^.gitlab-ci.yml \
:^.github/ \
2>&1 | tee check_for_todos_results.txt
@if [ ! -s check_for_todos_results.txt ]; then \
echo "Success: No TODO comments found."; \
else \
echo "Failure: Found TODO comments"; \
exit 1; \
fi
check-msrv:
@$(eval readme=$(shell grep "Rust \*\*....\*\*" README.md | cut -d'*' -f3-3))
@$(eval cargo=$(shell grep rust-version Cargo.toml | cut -d'"' -f2-2))
@echo README.md : $(readme)
@echo Cargo.toml: $(cargo)
@if [ "$(readme)" = "$(cargo)" ]; then \
echo "Success: MSRVs match."; \
else \
echo "Failure: MSRVs don't match."; \
exit 1; \
fi
run-pipeline-local: check-for-todos check-msrv
gitlab-runner exec shell fmt
gitlab-runner exec shell clippy
gitlab-runner exec shell default-latest
gitlab-runner exec shell default-nightly
gitlab-runner exec shell feature-latest
gitlab-runner exec shell feature-nightly