diff options
Diffstat (limited to 'rebar.config')
-rw-r--r-- | rebar.config | 68 |
1 files changed, 49 insertions, 19 deletions
diff --git a/rebar.config b/rebar.config index 36ce9a4..83da0e5 100644 --- a/rebar.config +++ b/rebar.config @@ -1,15 +1,31 @@ %% -*- mode: erlang;erlang-indent-level: 4;indent-tabs-mode: nil -*- %% ex: ts=4 sw=4 ft=erlang et -%% escript_incl_extra is for internal rebar-private use only. -%% Do not use outside rebar. Config interface is not stable. -{escript_incl_extra, [{"priv/templates/*", "."}, {"rebar/include/*", "."}]}. +{deps, [ + {erlware_commons, "", + {git, "https://github.com/erlware/erlware_commons.git", + {branch, "master"}}}, + {providers, "", + {git, "https://github.com/tsloughter/providers.git", + {tag, "v1.3.1"}}}, + {erlydtl, "", + {git, "https://github.com/erlydtl/erlydtl.git", + {branch, "master"}}}, + {relx, "", + {git, "https://github.com/erlware/relx.git", + {branch, "master"}}}, + {getopt, "", + {git, "https://github.com/jcomellas/getopt.git", + {branch, "master"}}}]}. {escript_incl_apps, [getopt, merl, erlydtl, erlware_commons, relx, providers, rebar]}. {escript_top_level_app, rebar}. {escript_name, rebar3}. {escript_emu_args, "%%! +sbtu +A0\n"}. +%% escript_incl_extra is for internal rebar-private use only. +%% Do not use outside rebar. Config interface is not stable. +{escript_incl_extra, [{"priv/templates/*", "."}, {"rebar/include/*", "."}]}. {erl_opts, [{platform_define, "R14", no_callback_support}, @@ -18,23 +34,37 @@ debug_info, warnings_as_errors]}. -{deps, [ - {erlware_commons, ".*", - {git, "https://github.com/erlware/erlware_commons.git", - {branch, "master"}}}, - {providers, "", - {git, "https://github.com/tsloughter/providers.git", - {tag, "v1.3.1"}}}, - {erlydtl, ".*", - {git, "https://github.com/erlydtl/erlydtl.git", - {tag, "0.10.0"}}}, - {relx, "", - {git, "https://github.com/erlware/relx.git", - {branch, "master"}}}, - {getopt, "", {git, "https://github.com/jcomellas/getopt.git", {branch, "master"}}}, - {meck, "", {git, "https://github.com/eproxus/meck.git", {tag, "0.8.2"}}}]}. - {erlydtl_opts, [{doc_root, "priv/templates"}, {compiler_options, [report, return, debug_info]}]}. {dialyzer_plt_apps, [common_test, dialyzer, erlydtl, eunit, snmp]}. + +{provider_hooks, [{post, [{compile, {erlydtl, compile}}]}]}. + +%% Profiles +{profiles, [{test, + [{deps, [ + {meck, "", {git, "https://github.com/eproxus/meck.git", {tag, "0.8.2"}}} + ]} + ] + }, + + %% We don't want erlydtl to attempt to run on the first compile pass to bootstrap + {bootstrap, [{overrides, [{override, relx, [{provider_hooks, [{post, []}]}]}]}, + {provider_hooks, [{post, []}]}]} + ]}. + +%% Overrides +{overrides, [{override, erlware_commons, [{plugins, []}]}, + {override, merl, [{pre_hooks, [{"(linux|darwin|solaris)", compile, "make -C \"$REBAR_DEPS_DIR/merl\" all -W test"}, + {"(freebsd|netbsd|openbsd)", compile, "gmake -C \"$REBAR_DEPS_DIR/merl\" all"}, + {"win32", compile, "make -C \"%REBAR_DEPS_DIR%/merl\" all -W test"}, + {eunit, + "erlc -I include/erlydtl_preparser.hrl -o test" + " test/erlydtl_extension_testparser.yrl"}, + {"(linux|darwin|solaris)", eunit, "make -C \"$REBAR_DEPS_DIR/merl\" test"}, + {"(freebsd|netbsd|openbsd)", eunit, "gmake -C \"$REBAR_DEPS_DIR/merl\" test"}, + {"win32", eunit, "make -C \"%REBAR_DEPS_DIR%/merl\" test"} + ]}]}, + {override, erlydtl, [{pre_hooks, []}]} + ]}. |