26 lines
466 B
Makefile
26 lines
466 B
Makefile
|
# Based on https://raw.githubusercontent.com/saschagrunert/webapp.rs/master/Makefile
|
||
|
|
||
|
.PHONY: \
|
||
|
build \
|
||
|
run
|
||
|
|
||
|
all: build
|
||
|
|
||
|
build:
|
||
|
wasm-pack build --target web --out-name wasm --out-dir ./static
|
||
|
|
||
|
build-doc:
|
||
|
cargo doc --all --no-deps
|
||
|
|
||
|
run:
|
||
|
simple-http-server -i ./static/ -p 3000 --nocache --try-file ./static/index.html
|
||
|
|
||
|
lint: lint-rustfmt lint-clippy
|
||
|
|
||
|
lint-clippy:
|
||
|
cargo clippy --all -- -D warnings
|
||
|
|
||
|
lint-rustfmt:
|
||
|
cargo fmt
|
||
|
git diff --exit-code
|