From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-626298-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 5FD281381F3 for <garchives@archives.gentoo.org>; Fri, 6 Sep 2013 11:11:06 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 49B1CE1032; Fri, 6 Sep 2013 11:11:01 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id CF7A6E1032 for <gentoo-commits@lists.gentoo.org>; Fri, 6 Sep 2013 11:11:00 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D4D8D33EB84 for <gentoo-commits@lists.gentoo.org>; Fri, 6 Sep 2013 11:10:59 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 8CE25E545E for <gentoo-commits@lists.gentoo.org>; Fri, 6 Sep 2013 11:10:58 +0000 (UTC) From: "André Erdmann" <dywi@mailerd.de> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "André Erdmann" <dywi@mailerd.de> Message-ID: <1378465672.c33afbec6517198fa9b8d076546c296ec6162cc3.dywi@gentoo> Subject: [gentoo-commits] proj/R_overlay:master commit in: files/hooks/ X-VCS-Repository: proj/R_overlay X-VCS-Files: files/hooks/mux.sh X-VCS-Directories: files/hooks/ X-VCS-Committer: dywi X-VCS-Committer-Name: André Erdmann X-VCS-Revision: c33afbec6517198fa9b8d076546c296ec6162cc3 X-VCS-Branch: master Date: Fri, 6 Sep 2013 11:10:58 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 6b2a64cd-c1a7-45ba-89f8-1fae5175be69 X-Archives-Hash: 269ee42a21b5d48b03ef7bc216aa25c9 commit: c33afbec6517198fa9b8d076546c296ec6162cc3 Author: André Erdmann <dywi <AT> mailerd <DOT> de> AuthorDate: Fri Sep 6 11:07:52 2013 +0000 Commit: André Erdmann <dywi <AT> mailerd <DOT> de> CommitDate: Fri Sep 6 11:07:52 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/R_overlay.git;a=commit;h=c33afbec files/hooks/mux.sh: preload extra function files --- files/hooks/mux.sh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/files/hooks/mux.sh b/files/hooks/mux.sh index c78d9e8..7789b99 100755 --- a/files/hooks/mux.sh +++ b/files/hooks/mux.sh @@ -30,9 +30,17 @@ for hookfile in \ ${FILESDIR}/hooks/?*.${ROVERLAY_PHASE} do if [ -f "${hookfile}" ]; then + # preload function files + hookfile_name="${hookfile##*/}" + case "${hookfile_name}" in + *git*) + $lf git + ;; + esac + # subshell: don't leak hook vars/functions ( - readonly hookfile_name="${hookfile##*/}" + readonly hookfile_name this="${hookfile_name#[0-9]*-}"; this="${this%.*}" if [ -n "${this}" ]; then @@ -47,6 +55,8 @@ do # initial directory should always be $S cd "${S}" && . "${hookfile}" ) || die "errors occured while running hook '${hookfile}'" + + unset -v hookfile_name fi done