-
Notifications
You must be signed in to change notification settings - Fork 196
/
Copy pathMakefile
35 lines (23 loc) · 1.06 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
.DEFAULT_GOAL := help
.PHONY: help
help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
# -- linting --------------------------------------------------------------------------------------
.PHONY: clippy
clippy: ## Runs Clippy with configs
cargo +nightly clippy --workspace --all-targets --features std,concurrent -- -D clippy::all -D warnings
.PHONY: fix
fix: ## Runs Fix with configs
cargo +nightly fix --allow-staged --allow-dirty --all-targets --features std,concurrent
.PHONY: format
format: ## Runs Format using nightly toolchain
cargo +nightly fmt --all
.PHONY: lint
lint: format fix clippy ## Runs all linting tasks at once (Clippy, fixing, formatting)
# --- building ------------------------------------------------------------------------------------
.PHONY: build
build: ## Builds with default parameters
cargo build
.PHONY: build-no-std
build-no-std: ## Builds without the standard library
cargo build --no-default-features --target wasm32-unknown-unknown --workspace