mirror of
https://github.com/correl/rebar.git
synced 2024-11-14 19:19:30 +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}}}}}
|
{AppFile, {expected, App}, {has, OtherApp}}}}}
|
||||||
end;
|
end;
|
||||||
false ->
|
false ->
|
||||||
?WARN("Expected ~s to be an app dir (containing ebin/*.app), "
|
case filelib:is_dir(Path) of
|
||||||
"but no .app found.\n", [Path]),
|
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}}}
|
{Config, {false, {missing_app_file, Path}}}
|
||||||
end;
|
end;
|
||||||
is_app_available(Config, App, _VsnRegex, Path, _IsRaw = true) ->
|
is_app_available(Config, App, _VsnRegex, Path, _IsRaw = true) ->
|
||||||
|
|
Loading…
Reference in a new issue