summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rebar.erl2
-rw-r--r--src/rebar_app_utils.erl4
-rw-r--r--src/rebar_templater.erl4
3 files changed, 5 insertions, 5 deletions
diff --git a/src/rebar.erl b/src/rebar.erl
index 797f71a..c0c6c97 100644
--- a/src/rebar.erl
+++ b/src/rebar.erl
@@ -99,7 +99,7 @@ run_aux(Commands) ->
erlang:put(operations, 0),
%% If $HOME/.rebar/config exists load and use as global config
- GlobalConfigFile = filename:join(os:getenv("HOME"), ".rebar/config"),
+ GlobalConfigFile = filename:join([os:getenv("HOME"), ".rebar", "config"]),
GlobalConfig = case filelib:is_regular(GlobalConfigFile) of
true ->
?DEBUG("Load global config file ~p~n",
diff --git a/src/rebar_app_utils.erl b/src/rebar_app_utils.erl
index 7e6cbd9..b47520a 100644
--- a/src/rebar_app_utils.erl
+++ b/src/rebar_app_utils.erl
@@ -45,12 +45,12 @@ is_app_dir() ->
is_app_dir(rebar_utils:get_cwd()).
is_app_dir(Dir) ->
- AppSrc = filename:join(Dir, "src/*.app.src"),
+ AppSrc = filename:join([Dir, "src", "*.app.src"]),
case filelib:wildcard(AppSrc) of
[AppSrcFile] ->
{true, AppSrcFile};
_ ->
- App = filename:join([Dir, "ebin/*.app"]),
+ App = filename:join([Dir, "ebin", "*.app"]),
case filelib:wildcard(App) of
[AppFile] ->
{true, AppFile};
diff --git a/src/rebar_templater.erl b/src/rebar_templater.erl
index 0bda300..865c8d5 100644
--- a/src/rebar_templater.erl
+++ b/src/rebar_templater.erl
@@ -200,8 +200,8 @@ find_escript_templates() ->
find_disk_templates() ->
OtherTemplates = find_other_templates(),
- HomeFiles = rebar_utils:find_files(filename:join(os:getenv("HOME"),
- ".rebar/templates"),
+ HomeFiles = rebar_utils:find_files(filename:join([os:getenv("HOME"),
+ ".rebar", "templates"]),
?TEMPLATE_RE),
LocalFiles = rebar_utils:find_files(".", ?TEMPLATE_RE),
[{file, F} || F <- OtherTemplates ++ HomeFiles ++ LocalFiles].