summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rebar_plugins.erl3
-rw-r--r--src/rebar_prv_clean.erl2
-rw-r--r--src/rebar_prv_packages.erl6
-rw-r--r--src/rebar_utils.erl6
4 files changed, 11 insertions, 6 deletions
diff --git a/src/rebar_plugins.erl b/src/rebar_plugins.erl
index 3e855de..bda3fb7 100644
--- a/src/rebar_plugins.erl
+++ b/src/rebar_plugins.erl
@@ -94,7 +94,8 @@ build_plugin(AppInfo, Apps, State) ->
Providers = rebar_state:providers(State),
Providers1 = rebar_state:providers(rebar_app_info:state(AppInfo)),
S = rebar_state:all_deps(rebar_app_info:state_or_new(State, AppInfo), Apps),
- rebar_prv_compile:compile(S, Providers++Providers1, AppInfo).
+ S1 = rebar_state:set(S, deps_dir, ?DEFAULT_PLUGINS_DIR),
+ rebar_prv_compile:compile(S1, Providers++Providers1, AppInfo).
plugin_providers({Plugin, _, _, _}) when is_atom(Plugin) ->
validate_plugin(Plugin);
diff --git a/src/rebar_prv_clean.erl b/src/rebar_prv_clean.erl
index e3cb84e..f10d12b 100644
--- a/src/rebar_prv_clean.erl
+++ b/src/rebar_prv_clean.erl
@@ -39,7 +39,7 @@ do(State) ->
case All of
true ->
DepsDir = rebar_dir:deps_dir(State),
- DepApps = rebar_app_discover:find_apps([DepsDir], all);
+ DepApps = rebar_app_discover:find_apps([filename:join(DepsDir, "*")], all);
false ->
DepApps = []
end,
diff --git a/src/rebar_prv_packages.erl b/src/rebar_prv_packages.erl
index 8ba66de..9a40734 100644
--- a/src/rebar_prv_packages.erl
+++ b/src/rebar_prv_packages.erl
@@ -46,7 +46,11 @@ print_packages(Dict) ->
end, orddict:new(), Pkgs),
orddict:map(fun(Name, Vsns) ->
- VsnStr = join(Vsns, <<", ">>),
+ SortedVsns = lists:sort(fun(A, B) ->
+ ec_semver:lte(ec_semver:parse(A)
+ ,ec_semver:parse(B))
+ end, Vsns),
+ VsnStr = join(SortedVsns, <<", ">>),
io:format("~s:~n Versions: ~s~n~n", [Name, VsnStr])
end, SortedPkgs).
diff --git a/src/rebar_utils.erl b/src/rebar_utils.erl
index c729b58..7ae3d9c 100644
--- a/src/rebar_utils.erl
+++ b/src/rebar_utils.erl
@@ -757,12 +757,12 @@ set_httpc_options(Scheme, Proxy) ->
escape_chars(Str) when is_atom(Str) ->
escape_chars(atom_to_list(Str));
escape_chars(Str) ->
- re:replace(Str, "([ ()?`!$])", "\\\\&", [global, {return, list}]).
+ re:replace(Str, "([ ()?`!$&;])", "\\\\&", [global, {return, list}]).
%% "escape inside these"
escape_double_quotes(Str) ->
- re:replace(Str, "([\"\\\\`!$*])", "\\\\&", [global, {return, list}]).
+ re:replace(Str, "([\"\\\\`!$&*;])", "\\\\&", [global, {return, list}]).
%% "escape inside these" but allow *
escape_double_quotes_weak(Str) ->
- re:replace(Str, "([\"\\\\`!$])", "\\\\&", [global, {return, list}]).
+ re:replace(Str, "([\"\\\\`!$&;])", "\\\\&", [global, {return, list}]).