From a3cd50792d0ed1c5dfee66ff79ee7117057e9970 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Hoguin?= Date: Fri, 7 Dec 2018 19:40:02 +0100 Subject: Autopatch: allow configuring REBAR_GIT and REBAR_COMMIT And use this in the tests to fetch Rebar only once and then clone from the local repository. This should speed up tests a little. --- core/deps.mk | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'core/deps.mk') diff --git a/core/deps.mk b/core/deps.mk index 8e18531..ed92daf 100644 --- a/core/deps.mk +++ b/core/deps.mk @@ -21,6 +21,9 @@ export DEPS_DIR REBAR_DEPS_DIR = $(DEPS_DIR) export REBAR_DEPS_DIR +REBAR_GIT ?= https://github.com/rebar/rebar +REBAR_COMMIT ?= 576e12171ab8d69b048b827b92aa65d067deea01 + # External "early" plugins (see core/plugins.mk for regular plugins). # They both use the core_dep_plugin macro. @@ -221,9 +224,9 @@ endef define dep_autopatch_fetch_rebar2 if [ ! -d $(ERLANG_MK_TMP)/rebar ]; then \ - git clone -q -n -- https://github.com/rebar/rebar $(ERLANG_MK_TMP)/rebar; \ + git clone -q -n -- $(REBAR_GIT) $(ERLANG_MK_TMP)/rebar; \ cd $(ERLANG_MK_TMP)/rebar; \ - git checkout -q 576e12171ab8d69b048b827b92aa65d067deea01; \ + git checkout -q $(REBAR_COMMIT); \ ./bootstrap; \ cd -; \ fi -- cgit v1.2.3