Skip to content

Commit

Permalink
Small improvement to the main Makefile.
Browse files Browse the repository at this point in the history
  • Loading branch information
danieltrick committed Oct 14, 2024
1 parent 6724f28 commit d04039c
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
include tools/docker/docker.mk

.SHELLFLAGS = -e -c

DOCKER := $(foreach target,$(DOCKER_TARGETS),docker.$(target))

.PHONY: all build check clean codecov docs examples libtpms package publish tests $(DOCKER)


all: clean check build

check:
Expand All @@ -18,12 +19,14 @@ tests:
build:
cargo build --release --locked

examples:
for i in $(basename $(notdir $(wildcard examples/*.rs))); do \
cargo run --example $$i; \
done

docs:
cargo doc --no-deps --locked

examples:
set -e; for i in examples/*.rs; do cargo run --example $$(basename $$i .rs); done

format:
cargo fmt --all $(if $(APPLY_FMT),,--check)

Expand Down

0 comments on commit d04039c

Please sign in to comment.