-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
33 lines (25 loc) · 694 Bytes
/
Makefile
File metadata and controls
33 lines (25 loc) · 694 Bytes
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
.PHONY: all run test clean
REBAR=$(shell which rebar || echo ./rebar)
all: $(REBAR)
$(REBAR) get-deps
$(REBAR) compile
run:
erl +Bd -noinput -noshell -sname erlysocks \
-boot start_sasl -config sys.config -s lager -s erlysocks_app
test:
$(REBAR) eunit skip_deps=true
clean:
$(REBAR) clean
$(REBAR) delete-deps
rm -rf ./rebar
rm -rf ./ebin
rm -rf ./deps
rm -rf ./log
rm -rf ./erl_crash.dump
# Get rebar if it doesn't exist
REBAR_URL=https://cloud.github.com/downloads/basho/rebar/rebar
./rebar:
erl -noinput -noshell -s inets -s ssl \
-eval '{ok, _} = httpc:request(get, {"${REBAR_URL}", []}, [], [{stream, "${REBAR}"}])' \
-s init stop
chmod +x ${REBAR}