From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 01FFF138334 for ; Sat, 15 Sep 2018 15:54:22 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 759AAE0BE5; Sat, 15 Sep 2018 15:54:18 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 20E11E0BE1 for ; Sat, 15 Sep 2018 15:54:17 +0000 (UTC) Received: from localhost.localdomain (d202-252.icpnet.pl [109.173.202.252]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: mgorny) by smtp.gentoo.org (Postfix) with ESMTPSA id 826CC335CE4; Sat, 15 Sep 2018 15:54:15 +0000 (UTC) From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= To: gentoo-dev@lists.gentoo.org Cc: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Subject: [gentoo-dev] [PATCH 1/2] git-r3.eclass: Print possible override vars for user convenience Date: Sat, 15 Sep 2018 17:54:08 +0200 Message-Id: <20180915155409.10368-1-mgorny@gentoo.org> X-Mailer: git-send-email 2.19.0 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Archives-Salt: ac121294-a1d6-4737-b124-6b30823f9a0a X-Archives-Hash: 4dfe8bee8cd907d3995a79b20bf273ff --- eclass/git-r3.eclass | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/eclass/git-r3.eclass b/eclass/git-r3.eclass index 48fac96ee358..3c09b6682ef5 100644 --- a/eclass/git-r3.eclass +++ b/eclass/git-r3.eclass @@ -586,6 +586,8 @@ git-r3_fetch() { local -x GIT_DIR _git-r3_set_gitdir "${repos[0]}" + einfo "Repository id: ${GIT_DIR##*/}" + # prepend the local mirror if applicable if [[ ${EGIT_MIRROR_URI} ]]; then repos=( @@ -618,10 +620,11 @@ git-r3_fetch() { COMMIT_DATE:commit_date ) - local localvar livevar live_warn= + local localvar livevar live_warn= override_vars=() for localvar in "${varmap[@]}"; do livevar=EGIT_OVERRIDE_${localvar%:*}_${override_name} localvar=${localvar#*:} + override_vars+=( "${livevar}" ) if [[ -n ${!livevar} ]]; then [[ ${localvar} == repos ]] && repos=() @@ -633,6 +636,13 @@ git-r3_fetch() { if [[ ${live_warn} ]]; then ewarn "No support will be provided." + else + einfo "To override fetched repository properties, use:" + local x + for x in "${override_vars[@]}"; do + einfo " ${x}" + done + einfo fi fi -- 2.19.0