From 266d82f871de7d6fec3aa34909a6c5373f74e009 Mon Sep 17 00:00:00 2001 From: Dave Smith Date: Sat, 17 Apr 2010 07:34:54 -0600 Subject: [PATCH] Add simple warning if no modules are interested in handling a command for a given directory --- src/rebar_core.erl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/rebar_core.erl b/src/rebar_core.erl index a6f2c68..0304201 100644 --- a/src/rebar_core.erl +++ b/src/rebar_core.erl @@ -264,6 +264,7 @@ process_dir(Dir, ParentConfig, Commands) -> ok = file:set_cwd(Dir), %% Finally, process the current working directory + ?DEBUG("Commands: ~p Modules: ~p\n", [Commands, Modules]), apply_commands(Commands, Modules, UpdatedConfig, ModuleSetFile), %% Once we're all done processing, reset the code path to whatever @@ -306,6 +307,8 @@ apply_commands([], _Modules, _Config, _ModuleFile) -> apply_commands([Command | Rest], Modules, Config, ModuleFile) -> case select_modules(Modules, Command, []) of [] -> + ?CONSOLE("WARNING: ~p command does not apply to directory ~s\n", + [Command, rebar_utils:get_cwd()]), apply_commands(Rest, Modules, Config, ModuleFile); TargetModules -> %% Provide some info on where we are