summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/rebar.erl4
-rw-r--r--src/rebar_upgrade.erl8
2 files changed, 6 insertions, 6 deletions
diff --git a/src/rebar.erl b/src/rebar.erl
index 86b3734..ea3a2ab 100644
--- a/src/rebar.erl
+++ b/src/rebar.erl
@@ -87,7 +87,9 @@ run(["help"|RawCmds]) when RawCmds =/= [] ->
run(["help"]) ->
help();
run(["info"|_]) ->
- help();
+ %% Catch calls to 'rebar info' to avoid treating plugins' info/2 functions
+ %% as commands.
+ ?CONSOLE("Command 'info' not understood or not applicable~n", []);
run(["version"]) ->
ok = load_rebar_app(),
%% Display vsn and build time info
diff --git a/src/rebar_upgrade.erl b/src/rebar_upgrade.erl
index 5814e51..3a38a08 100644
--- a/src/rebar_upgrade.erl
+++ b/src/rebar_upgrade.erl
@@ -87,7 +87,8 @@ info(help, 'generate-upgrade') ->
?CONSOLE("Build an upgrade package.~n"
"~n"
"Valid command line options:~n"
- " previous_release=path~n",
+ " previous_release=path~n"
+ " target_dir=target_dir (optional)~n",
[]).
run_checks(Config, OldVerPath, ReltoolConfig) ->
@@ -97,10 +98,7 @@ run_checks(Config, OldVerPath, ReltoolConfig) ->
{Name, Ver} = rebar_rel_utils:get_reltool_release_info(ReltoolConfig),
- NewVerPath =
- filename:join(
- [rebar_rel_utils:get_target_parent_dir(Config, ReltoolConfig),
- Name]),
+ NewVerPath = rebar_rel_utils:get_target_dir(Config, ReltoolConfig),
true = rebar_utils:prop_check(filelib:is_dir(NewVerPath),
"Release directory doesn't exist (~p)~n",
[NewVerPath]),