summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Junghans <junghans@gentoo.org>2017-02-12 10:50:10 -0700
committerChristoph Junghans <junghans@gentoo.org>2018-05-06 07:13:42 -0600
commitff7ab2347b054f1f621f13036309be2d4cb020b2 (patch)
tree3503d6740814ce58025c105165e80f738e374b2d /eclass/mercurial.eclass
parentx11-drivers/nvidia-drivers: Old. (diff)
downloadgentoo-ff7ab2347b054f1f621f13036309be2d4cb020b2.tar.gz
gentoo-ff7ab2347b054f1f621f13036309be2d4cb020b2.tar.bz2
gentoo-ff7ab2347b054f1f621f13036309be2d4cb020b2.zip
mercurial.eclass: add EHG_CONFIG (bug #608974)
Closes: https://bugs.gentoo.org/608974
Diffstat (limited to 'eclass/mercurial.eclass')
-rw-r--r--eclass/mercurial.eclass9
1 files changed, 7 insertions, 2 deletions
diff --git a/eclass/mercurial.eclass b/eclass/mercurial.eclass
index ad3102b7590d..9a5bd191c231 100644
--- a/eclass/mercurial.eclass
+++ b/eclass/mercurial.eclass
@@ -57,15 +57,19 @@ DEPEND="dev-vcs/mercurial"
: ${EHG_QUIET:="OFF"}
[[ "${EHG_QUIET}" == "ON" ]] && EHG_QUIET_CMD_OPT="--quiet"
+# @ECLASS-VARIABLE: EHG_CONFIG
+# @DESCRIPTION:
+# Extra config option to hand to hg clone/pull
+
# @ECLASS-VARIABLE: EHG_CLONE_CMD
# @DESCRIPTION:
# Command used to perform initial repository clone.
-[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone ${EHG_QUIET_CMD_OPT} --pull --noupdate"
+[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone ${EHG_CONFIG:+--config ${EHG_CONFIG}} ${EHG_QUIET_CMD_OPT} --pull --noupdate"
# @ECLASS-VARIABLE: EHG_PULL_CMD
# @DESCRIPTION:
# Command used to update repository.
-[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull ${EHG_QUIET_CMD_OPT}"
+[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull ${EHG_CONFIG:+--config ${EHG_CONFIG}} ${EHG_QUIET_CMD_OPT}"
# @ECLASS-VARIABLE: EHG_OFFLINE
# @DESCRIPTION:
@@ -134,6 +138,7 @@ mercurial_fetch() {
hg clone \
${EHG_QUIET_CMD_OPT} \
--updaterev="${EHG_REVISION}" \
+ ${EHG_CONFIG:+--config ${EHG_CONFIG}} \
"${EHG_STORE_DIR}/${EHG_PROJECT}/${module}" \
"${sourcedir}" || die "hg clone failed"
# An exact revision helps a lot for testing purposes, so have some output...