From 3152411f229950bcbb71aad35b707c3890c208e1 Mon Sep 17 00:00:00 2001 From: Manos Pitsidianakis Date: Sun, 26 Jul 2020 02:40:01 +0300 Subject: [PATCH] Fix Makefile semantics Makefile targets didn't correspond to the widely used ones: - make should build meli instead of showing help - make check should run tests Closes #42 --- Makefile | 9 ++++++--- README.md | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 206e8830..459963da 100644 --- a/Makefile +++ b/Makefile @@ -44,6 +44,9 @@ GREEN ?= `[ -z $${NO_COLOR+x} ] && ([ -z $${TERM} ] && echo "" || tput setaf 2) .POSIX: .SUFFIXES: +meli: check-deps + @${CARGO_BIN} build ${CARGO_COLOR}--target-dir="${CARGO_TARGET_DIR}" ${FEATURES} --release + help: @echo "For a quick start, build and install locally:\n ${BOLD}${GREEN}PREFIX=~/.local make install${ANSI_RESET}\n" @echo "Available subcommands:" @@ -79,9 +82,9 @@ help: @echo ${ANSI_RESET} @#@echo "* CARGO_COLOR = ${CARGO_COLOR}" -meli: check-deps - @${CARGO_BIN} build ${CARGO_COLOR}--target-dir="${CARGO_TARGET_DIR}" ${FEATURES} --release - +.PHONY: check +check: + @${CARGO_BIN} test ${CARGO_COLOR}--target-dir="${CARGO_TARGET_DIR}" --workspace .PHONY: check-deps check-deps: diff --git a/README.md b/README.md index 2900dbf5..12854145 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ to get it on your system can be found here: