-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
61 lines (47 loc) · 930 Bytes
/
Makefile
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
61
ELVIS_IN_PATH := $(shell elvis --version 2> /dev/null)
ELVIS_LOCAL := $(shell .elvis/_build/default/bin/elvis --version 2> /dev/null)
all: compile
compile:
rebar3 compile
clean:
rebar3 clean
eunit:
rebar3 eunit
ct:
rebar3 ct -v
xref:
rebar3 xref
dialyze:
rebar3 dialyzer
upgrade:
rebar3 upgrade
unlock:
rebar3 unlock
lock:
rebar3 lock
docs:
rebar3 edoc
elvis:
ifdef ELVIS_IN_PATH
elvis git-branch origin/HEAD -V
else ifdef ELVIS_LOCAL
.elvis/_build/default/bin/elvis git-branch origin/HEAD -V
else
$(MAKE) compile_elvis
.elvis/_build/default/bin/elvis git-branch origin/HEAD -V
endif
elvis_rock:
ifdef ELVIS_IN_PATH
elvis rock
else ifdef ELVIS_LOCAL
.elvis/_build/default/bin/elvis rock
else
$(MAKE) compile_elvis
.elvis/_build/default/bin/elvis rock
endif
compile_elvis:
git clone https://github.com/inaka/elvis.git .elvis && \
cd .elvis && \
rebar3 compile && \
rebar3 escriptize && \
cd ..