diff options
author | Tristan Sloughter <t@crashfast.com> | 2014-12-21 14:38:36 -0600 |
---|---|---|
committer | Tristan Sloughter <t@crashfast.com> | 2014-12-21 14:38:36 -0600 |
commit | 9a8b1b329051ef69d791fc12e0a410171f01ad7e (patch) | |
tree | 2687e49eb3850d3933c90aee37619a8fe2cbc569 | |
parent | 3aeb76c10b7f9311b4070d473f39032996170145 (diff) |
update erlydtl provider to use namespaces
-rw-r--r-- | src/rebar_prv_erlydtl_compiler.erl | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/rebar_prv_erlydtl_compiler.erl b/src/rebar_prv_erlydtl_compiler.erl index 8ae6d03..a922404 100644 --- a/src/rebar_prv_erlydtl_compiler.erl +++ b/src/rebar_prv_erlydtl_compiler.erl @@ -105,7 +105,7 @@ -include("rebar.hrl"). --define(PROVIDER, erlydtl). +-define(PROVIDER, compile). -define(DEPS, []). %% =================================================================== @@ -116,9 +116,10 @@ init(State) -> State1 = rebar_state:add_provider(State, providers:create([{name, ?PROVIDER}, {module, ?MODULE}, + {namespace, erlydtl}, {bare, false}, {deps, ?DEPS}, - {example, "rebar erlydtl compile"}, + {example, "rebar3 erlydtl compile"}, {short_desc, "Compile erlydtl templates."}, {desc, ""}, {opts, []}])), @@ -126,8 +127,6 @@ init(State) -> do(Config) -> MultiDtlOpts = erlydtl_opts(Config), - OrigPath = code:get_path(), - %true = code:add_path(rebar_utils:ebin_dir()), Result = lists:foldl(fun(DtlOpts, _) -> file:make_dir(option(out_dir, DtlOpts)), @@ -143,7 +142,6 @@ do(Config) -> {recursive, option(recursive, DtlOpts)}]) end, ok, MultiDtlOpts), - true = code:set_path(OrigPath), {Result, Config}. -spec format_error(any()) -> iolist(). |