Skip to content

Commit f0c3504

Browse files
committed
Merge pull request #17 from danikp/ChicagoBoss-master
update for Erlang 18
2 parents 4a9ffe0 + 1b78efb commit f0c3504

File tree

5 files changed

+50
-54
lines changed

5 files changed

+50
-54
lines changed

.travis.yml

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,28 @@
11
language: erlang
2+
sudo: false
23
otp_release:
4+
# Test on all supported releases
5+
- 18.0
6+
- 17.5
7+
- 17.4
8+
- 17.3
39
- 17.1
410
- 17.0
511
- R16B03-1
12+
- R16B03
613
- R16B02
714
- R16B01
15+
- R16B
16+
- R15B03
17+
# - R15B02 #fails
18+
- R15B01
19+
- R15B
820

921
script:
10-
- rebar get-deps
11-
- rebar compile
22+
- make
1223
- rebar eunit -v skip_deps=true
1324
- make test
14-
- mkdir plt
15-
- ./travis-dialyzer.sh
25+
- make plt
26+
- make dialyze
1627
notifications:
17-
email: false
28+
email: false

Makefile

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
ERL=erl
22
REBAR=./rebar
33
GIT = git
4-
REBAR_VER = 2.5.1
4+
REBAR_VER = 2.6.0
5+
6+
.PHONY: get-deps
57

68
all: compile
79

@@ -17,14 +19,39 @@ test: compile compile_test
1719
$(ERL) -noshell -pa ebin -pa ebintest -pa deps/tiny_pq/ebin \
1820
-s tinymq_test run_tests \
1921
-s init stop
20-
21-
clean:
22-
@$(REBAR) clean
23-
22+
2423
rebar_src:
2524
@rm -rf $(PWD)/rebar_src
2625
@$(GIT) clone git://github.com/rebar/rebar.git rebar_src
2726
@$(GIT) -C rebar_src checkout tags/$(REBAR_VER)
2827
@cd $(PWD)/rebar_src/; ./bootstrap
2928
@cp $(PWD)/rebar_src/rebar $(PWD)
3029
@rm -rf $(PWD)/rebar_src
30+
31+
get-deps:
32+
@$(REBAR) get-deps
33+
34+
## dialyzer
35+
PLT_FILE = ~/tiny_pq.plt
36+
PLT_APPS ?= kernel stdlib erts compiler deps/*
37+
DIALYZER_OPTS ?= -Werror_handling -Wrace_conditions -Wunmatched_returns \
38+
-Wunderspecs --verbose --fullpath -n
39+
40+
.PHONY: dialyze
41+
dialyze: all
42+
@[ -f $(PLT_FILE) ] || $(MAKE) plt
43+
@dialyzer --plt $(PLT_FILE) $(DIALYZER_OPTS) ebin || [ $$? -eq 2 ];
44+
45+
## In case you are missing a plt file for dialyzer,
46+
## you can run/adapt this command
47+
.PHONY: plt
48+
plt:
49+
@echo "Building PLT, may take a few minutes"
50+
@dialyzer --build_plt --output_plt $(PLT_FILE) --apps \
51+
$(PLT_APPS) || [ $$? -eq 2 ];
52+
53+
clean:
54+
@$(REBAR) clean
55+
rm -fv erl_crash.dump
56+
rm -f $(PLT_FILE)
57+

rebar.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{erl_opts, [debug_info]}.
22
{deps, [
3-
{tiny_pq, ".*", {git, "git://github.com/ChicagoBoss/tiny_pq.git", {tag, "v0.8.14"}}}
3+
{tiny_pq, ".*", {git, "git://github.com/ChicagoBoss/tiny_pq.git", {tag, "v0.8.15"}}}
44
]}.

src/tinymq.app.src

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{application, tinymq,
22
[
33
{description, "TinyMQ: a diminutive message queue"},
4-
{vsn, "0.1.2"},
4+
{vsn, "0.8.15"},
55
{registered, [tinymq]},
66
{modules, []},
77
{applications, [

travis-dialyzer.sh

Lines changed: 0 additions & 42 deletions
This file was deleted.

0 commit comments

Comments
 (0)