diff options
author | Tuncer Ayaz <tuncer.ayaz@gmail.com> | 2011-07-06 21:22:04 +0200 |
---|---|---|
committer | Tuncer Ayaz <tuncer.ayaz@gmail.com> | 2011-07-08 13:40:47 +0200 |
commit | 1ec92ebac3f05faeb26403a2a3b079a8db80d2fb (patch) | |
tree | c44fc4aca371a7edadef869225ad3951c5a8924f | |
parent | 0f08e768a7e235b892f69870d27fd7bc21685f57 (diff) |
Do not warn if pre_/post_ cmd is not available
-rw-r--r-- | src/rebar_core.erl | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/rebar_core.erl b/src/rebar_core.erl index 9a8814d..790edc9 100644 --- a/src/rebar_core.erl +++ b/src/rebar_core.erl @@ -241,8 +241,15 @@ execute_plugin_hook(Hook, Command, Modules, Config, ModuleFile) -> execute(Command, Modules, Config, ModuleFile) -> case select_modules(Modules, Command, []) of [] -> - ?WARN("'~p' command does not apply to directory ~s\n", - [Command, rebar_utils:get_cwd()]); + Cmd = atom_to_list(Command), + case lists:prefix("pre_", Cmd) + orelse lists:prefix("post_", Cmd) of + true -> + ok; + false -> + ?WARN("'~p' command does not apply to directory ~s\n", + [Command, rebar_utils:get_cwd()]) + end; TargetModules -> %% Provide some info on where we are |