From c807e23b6c323ca59d7f3d249251aaff9bac3fdd Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 8 Jul 2007 07:28:02 +0000 Subject: For bug #184566, enable the emerge --info action to run an option pkg_info() function from each installed ebuild. (trunk r7201) svn path=/main/branches/2.1.2/; revision=7202 --- 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 117268230..cc09080bd 100755 --- a/bin/ebuild.sh +++ b/bin/ebuild.sh @@ -1616,7 +1616,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