Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 16 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
language: erlang
sudo: false
otp_release:
# Test on all supported releases
- 18.0
- 17.5
- 17.4
- 17.3
- 17.1
- 17.0
- R16B03-1
- R16B03
- R16B02
- R16B01
- R16B
- R15B03
# - R15B02 #fails
- R15B01
- R15B

script:
- rebar get-deps
- rebar compile
- make
- rebar eunit -v skip_deps=true
- make test
- mkdir plt
- ./travis-dialyzer.sh
- make plt
- make dialyze
notifications:
email: false
email: false
37 changes: 32 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
ERL=erl
REBAR=./rebar
GIT = git
REBAR_VER = 2.5.1
REBAR_VER = 2.6.0

.PHONY: get-deps

all: compile

Expand All @@ -17,14 +19,39 @@ test: compile compile_test
$(ERL) -noshell -pa ebin -pa ebintest -pa deps/tiny_pq/ebin \
-s tinymq_test run_tests \
-s init stop

clean:
@$(REBAR) clean


rebar_src:
@rm -rf $(PWD)/rebar_src
@$(GIT) clone git://github.com/rebar/rebar.git rebar_src
@$(GIT) -C rebar_src checkout tags/$(REBAR_VER)
@cd $(PWD)/rebar_src/; ./bootstrap
@cp $(PWD)/rebar_src/rebar $(PWD)
@rm -rf $(PWD)/rebar_src

get-deps:
@$(REBAR) get-deps

## dialyzer
PLT_FILE = ~/tiny_pq.plt
PLT_APPS ?= kernel stdlib erts compiler deps/*
DIALYZER_OPTS ?= -Werror_handling -Wrace_conditions -Wunmatched_returns \
-Wunderspecs --verbose --fullpath -n

.PHONY: dialyze
dialyze: all
@[ -f $(PLT_FILE) ] || $(MAKE) plt
@dialyzer --plt $(PLT_FILE) $(DIALYZER_OPTS) ebin || [ $$? -eq 2 ];

## In case you are missing a plt file for dialyzer,
## you can run/adapt this command
.PHONY: plt
plt:
@echo "Building PLT, may take a few minutes"
@dialyzer --build_plt --output_plt $(PLT_FILE) --apps \
$(PLT_APPS) || [ $$? -eq 2 ];

clean:
@$(REBAR) clean
rm -fv erl_crash.dump
rm -f $(PLT_FILE)

2 changes: 1 addition & 1 deletion rebar.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{erl_opts, [debug_info]}.
{deps, [
{tiny_pq, ".*", {git, "git://github.com/ChicagoBoss/tiny_pq.git", {tag, "v0.8.14"}}}
{tiny_pq, ".*", {git, "git://github.com/ChicagoBoss/tiny_pq.git", {tag, "v0.8.15"}}}
]}.
2 changes: 1 addition & 1 deletion src/tinymq.app.src
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{application, tinymq,
[
{description, "TinyMQ: a diminutive message queue"},
{vsn, "0.1.2"},
{vsn, "0.8.15"},
{registered, [tinymq]},
{modules, []},
{applications, [
Expand Down
42 changes: 0 additions & 42 deletions travis-dialyzer.sh

This file was deleted.