X-Git-Url: https://git.r.bdr.sh/rbdr/lyricli/blobdiff_plain/534287c397b5caec8a6e2b261e62b0ec2726592f..e4117b21a5e9cfaa3278e9e25711aff363e2ac92:/Makefile?ds=sidebyside diff --git a/Makefile b/Makefile index 50cebd1..766196f 100644 --- a/Makefile +++ b/Makefile @@ -15,6 +15,18 @@ prepare: build: prepare @export $$(cat .env | xargs) > /dev/null 2>&1 && cargo build --profile $(profile) --target $(target) +test: + @export $$(cat .env | xargs) > /dev/null 2>&1 && cargo test + +coverage: + @export $$(cat .env | xargs) > /dev/null 2>&1 && cargo tarpaulin + +format: + @export $$(cat .env | xargs) > /dev/null 2>&1 && cargo fmt && cargo clippy --fix + +lint: + @export $$(cat .env | xargs) > /dev/null 2>&1 && cargo fmt -- --check && cargo clippy + release: rpm tar deb @$(eval filename := $(app_name)-$(target)-$(channel)) @@ -62,8 +74,7 @@ else $(MAKE) -e profile=release -e architectures='$(mac_architectures)' -e channel=$(tag) package endif - -ci: +ci: lint coverage ifeq ($(GIT_REF),refs/heads/main) $(MAKE) -e profile=release -e channel=unstable package else ifneq (,$(findstring refs/tags/,$(GIT_REF)))