-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
60 lines (49 loc) · 1.23 KB
/
Makefile
File metadata and controls
60 lines (49 loc) · 1.23 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Use one shell for the whole recipe, instead of per-line
.ONESHELL:
# Use bash in strict mode
SHELL := bash
.SHELLFLAGS = -eu -o pipefail -c
# Sane makefile settings to avoid the unexpected
MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules --no-builtin-variables
# Provide a command to source the env.sh file if any
source ?= source env.sh || true
# All the ex files
ex_files = $(shell find . -name '*.ex')
# All the exs files
exs_files = $(shell find . -name '*.exs')
deps: mix.exs mix.lock
@echo "📦 Download the project dependencies"
mix deps.get
touch $@
doc: deps $(ex_files)
@echo "📚 Create the documentation"
mix docs
touch $@
.PHONY: qa dialyzer dialixir
dialyzer: qa
dialixir: qa
qa: deps
@echo "🕵️♀️ Run dialyzer"
mix dialyzer
.PHONY: test
test: deps
@echo "🧪 Run the tests"
mix test
.PHONY: test-watch
test-watch: deps
@echo "🥽 Run the tests on changes"
mix test.watch
.PHONY: test-tezos
test-tezos: deps
@echo "🧪 Run the tezos tests"
mix test --only tezos
.PHONY: coverage
coverage: cover
cover: deps $(ex_files) $(exs_files)
@echo "🔍 Generate the coverage report"
mix coveralls.html
touch $@
clean-all:
@echo "🗑 Clean all artifacts"
rm -rf deps _build cover doc