summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTuncer Ayaz <tuncer.ayaz@gmail.com>2012-05-13 19:26:29 +0200
committerTuncer Ayaz <tuncer.ayaz@gmail.com>2012-05-13 19:30:38 +0200
commit32ddef7158aa66e1a39160108dd769f9205111ee (patch)
tree2461bd780e7810e713173b2159907da730ca4609
parente6d5a494b047566ece90ef8c8ab52bcbefb75053 (diff)
downloadrebar-32ddef7158aa66e1a39160108dd769f9205111ee.tar.gz
Remove alt_url support in favor of new features
-rw-r--r--priv/shell-completion/bash/rebar3
-rw-r--r--rebar.config.sample5
-rw-r--r--src/rebar_deps.erl17
3 files changed, 3 insertions, 22 deletions
diff --git a/priv/shell-completion/bash/rebar b/priv/shell-completion/bash/rebar
index c8690c2..964c1ad 100644
--- a/priv/shell-completion/bash/rebar
+++ b/priv/shell-completion/bash/rebar
@@ -12,8 +12,7 @@ _rebar()
ct doc delete-deps eunit get-deps generate generate-upgrade \
help list-deps list-templates update-deps version xref overlay \
apps= case= force=1 jobs= suites= verbose=1 appid= previous_release= \
- nodeid= root_dir= skip_deps=true skip_apps= template= template_dir= \
- alt_urls=true"
+ nodeid= root_dir= skip_deps=true skip_apps= template= template_dir="
if [[ ${cur} == --* ]] ; then
COMPREPLY=( $(compgen -W "${lopts}" -- ${cur}) )
diff --git a/rebar.config.sample b/rebar.config.sample
index ebcaff9..dc4253b 100644
--- a/rebar.config.sample
+++ b/rebar.config.sample
@@ -115,10 +115,7 @@
{deps, [application_name,
{application_name, "1.0.*"},
{application_name, "1.0.*",
- {git, "git://github.com/basho/rebar.git", {branch, "master"}}},
- {application_name, "1.0.*",
- {git, "git://github.com/basho/rebar.git", {branch, "master"}},
- [{alt_url, "https://github.com/basho/rebar.git"}]}]}.
+ {git, "git://github.com/basho/rebar.git", {branch, "master"}}}]}.
%% == Subdirectories ==
diff --git a/src/rebar_deps.erl b/src/rebar_deps.erl
index c64d761..8a8e26f 100644
--- a/src/rebar_deps.erl
+++ b/src/rebar_deps.erl
@@ -229,30 +229,15 @@ find_deps(Mode, [App | Rest], Acc) when is_atom(App) ->
find_deps(Mode, [{App, VsnRegex} | Rest], Acc) when is_atom(App) ->
find_deps(Mode, [{App, VsnRegex, undefined} | Rest], Acc);
find_deps(Mode, [{App, VsnRegex, Source} | Rest], Acc) ->
- find_deps(Mode, [{App, VsnRegex, Source, []} | Rest], Acc);
-find_deps(Mode, [{App, VsnRegex, Source, Opts} | Rest], Acc) ->
Dep = #dep { app = App,
vsn_regex = VsnRegex,
- source = get_source(Source, Opts) },
+ source = Source },
{Availability, FoundDir} = find_dep(Dep),
find_deps(Mode, Rest, acc_deps(Mode, Availability, Dep, FoundDir, Acc));
find_deps(_Mode, [Other | _Rest], _Acc) ->
?ABORT("Invalid dependency specification ~p in ~s\n",
[Other, rebar_utils:get_cwd()]).
-get_source(undefined, _Opts) ->
- undefined;
-get_source(Source, Opts) ->
- setelement(2, Source, dep_url(element(2, Source), Opts)).
-
-dep_url(Url, Opts) ->
- case rebar_config:get_global(alt_urls, "false") of
- "true" ->
- proplists:get_value(alt_url, Opts, Url);
- "false" ->
- Url
- end.
-
find_dep(Dep) ->
%% Find a dep based on its source,
%% e.g. {git, "https://github.com/mochi/mochiweb.git", "HEAD"}