mirror of
https://github.com/correl/rebar.git
synced 2024-12-24 11:50:52 +00:00
Merge pull request #444 from tuncer/app-warning
Fix incorrect "not an app dir" warning
This commit is contained in:
commit
48e041dd9e
1 changed files with 13 additions and 2 deletions
|
@ -457,8 +457,19 @@ is_app_available(Config, App, VsnRegex, Path, _IsRaw = false) ->
|
|||
{AppFile, {expected, App}, {has, OtherApp}}}}}
|
||||
end;
|
||||
false ->
|
||||
?WARN("Expected ~s to be an app dir (containing ebin/*.app), "
|
||||
"but no .app found.\n", [Path]),
|
||||
case filelib:is_dir(Path) of
|
||||
true ->
|
||||
%% Path is a directory, but it's not an app dir.
|
||||
?WARN("Directory expected to be an app dir, but no "
|
||||
"app file found ~n"
|
||||
"in ebin/ or src/:~n~s~n",
|
||||
[Path]);
|
||||
false ->
|
||||
%% Path is not a directory, so it cannot be an app dir.
|
||||
%% TODO: maybe we can avoid checking non-existing dirs
|
||||
?DEBUG("Directory expected to be an app dir, "
|
||||
"but it doesn't exist (yet?):~n~s~n", [Path])
|
||||
end,
|
||||
{Config, {false, {missing_app_file, Path}}}
|
||||
end;
|
||||
is_app_available(Config, App, _VsnRegex, Path, _IsRaw = true) ->
|
||||
|
|
Loading…
Reference in a new issue