mirror of
https://github.com/correl/rebar.git
synced 2024-12-24 03:00:16 +00:00
Refactor ci support
This commit is contained in:
parent
c64c809faf
commit
35ef3631b4
3 changed files with 37 additions and 4 deletions
|
@ -6,4 +6,4 @@ otp_release:
|
|||
- R15B
|
||||
- R14B04
|
||||
- R14B03
|
||||
before_script: "./bootstrap"
|
||||
script: "make all deps test"
|
||||
|
|
19
Makefile
19
Makefile
|
@ -1,4 +1,9 @@
|
|||
.PHONY: dialyzer_warnings xref_warnings
|
||||
.PHONY: dialyzer_warnings xref_warnings deps test
|
||||
|
||||
REBAR=$(PWD)/rebar
|
||||
RETEST=$(PWD)/deps/retest/retest
|
||||
EUNIT_DIR=$(PWD)/.eunit
|
||||
RETEST_DIR=$(PWD)/.rt.work
|
||||
|
||||
all:
|
||||
./bootstrap
|
||||
|
@ -9,7 +14,7 @@ clean:
|
|||
debug:
|
||||
@./bootstrap debug
|
||||
|
||||
check: debug xref dialyzer
|
||||
check: debug xref dialyzer deps test
|
||||
|
||||
xref:
|
||||
@./rebar xref
|
||||
|
@ -24,4 +29,12 @@ dialyzer_warnings:
|
|||
binary: VSN = $(shell ./rebar -V)
|
||||
binary: clean all
|
||||
cp rebar ../rebar.wiki/rebar
|
||||
(cd ../rebar.wiki && git commit -m "Update $(VSN)" rebar)
|
||||
(cd ../rebar.wiki && git commit -m "Update $(VSN)" rebar)
|
||||
|
||||
deps:
|
||||
REBAR_EXTRA_DEPS=1 ./rebar get-deps
|
||||
cd deps/retest && $(REBAR) compile escriptize
|
||||
|
||||
test:
|
||||
$(REBAR) eunit
|
||||
$(RETEST) inttest
|
||||
|
|
20
rebar.config.script
Normal file
20
rebar.config.script
Normal file
|
@ -0,0 +1,20 @@
|
|||
%% -*- mode: erlang;erlang-indent-level: 4;indent-tabs-mode: nil -*-
|
||||
%% ex: ts=4 sw=4 ft=erlang et
|
||||
|
||||
%% TODO: Change temporary retest fork back to dizzyd/retest after merge
|
||||
%% ExtraDeps = [{retest, ".*", {git, "git://github.com/dizzyd/retest.git"}}],
|
||||
ExtraDeps = [{retest, ".*",
|
||||
{git, "git://github.com/tuncer/retest.git", "next"}}],
|
||||
|
||||
case os:getenv("REBAR_EXTRA_DEPS") of
|
||||
false ->
|
||||
CONFIG;
|
||||
_ ->
|
||||
case lists:keysearch(deps, 1, CONFIG) of
|
||||
{value, {deps, Deps}} ->
|
||||
NDeps = Deps ++ ExtraDeps,
|
||||
lists:keyreplace(deps, 1, CONFIG, {deps, NDeps});
|
||||
false ->
|
||||
CONFIG ++ [{deps, ExtraDeps}]
|
||||
end
|
||||
end.
|
Loading…
Reference in a new issue