From ac0a630b42c12b5f0d3088d4f4c45186c82d3d57 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 8 Jul 2007 07:24:12 +0000 Subject: For bug #184566, enable the emerge --info action to run an option pkg_info() function from each installed ebuild. svn path=/main/trunk/; revision=7201 --- bin/ebuild.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'bin/ebuild.sh') diff --git a/bin/ebuild.sh b/bin/ebuild.sh index ffe904e9c..b7636b1e3 100755 --- a/bin/ebuild.sh +++ b/bin/ebuild.sh @@ -1538,7 +1538,12 @@ for myarg in ${EBUILD_SH_ARGS} ; do qa_call pkg_nofetch exit 1 ;; - prerm|postrm|postinst|config) + prerm|postrm|postinst|config|info) + if [ "${myarg}" == "info" ] && \ + [ "$(type -t pkg_${myarg})" != "function" ]; then + ewarn "pkg_${myarg}() is not defined: '${EBUILD##*/}'" + continue + fi export SANDBOX_ON="0" if [ "$PORTAGE_DEBUG" != "1" ]; then [ "$(type -t pre_pkg_${myarg})" == "function" ] && qa_call pre_pkg_${myarg} -- cgit v1.2.3-1-g7c22