From 546650c382145559cb3e3d145010a7e856a5e5f1 Mon Sep 17 00:00:00 2001 From: Thomas Deutschmann Date: Mon, 24 Aug 2020 14:36:13 +0200 Subject: sys-fs/lvm2: show some ewarns in pkg_postinst only once Package-Manager: Portage-3.0.4, Repoman-3.0.1 Signed-off-by: Thomas Deutschmann --- sys-fs/lvm2/lvm2-2.02.187-r2.ebuild | 13 ++++++++----- sys-fs/lvm2/lvm2-2.03.10.ebuild | 10 ++++++++-- 2 files changed, 16 insertions(+), 7 deletions(-) (limited to 'sys-fs/lvm2') diff --git a/sys-fs/lvm2/lvm2-2.02.187-r2.ebuild b/sys-fs/lvm2/lvm2-2.02.187-r2.ebuild index 3111a305fc4f..2bc6f354e530 100644 --- a/sys-fs/lvm2/lvm2-2.02.187-r2.ebuild +++ b/sys-fs/lvm2/lvm2-2.02.187-r2.ebuild @@ -266,11 +266,14 @@ src_install() { } pkg_postinst() { - ewarn "Make sure the \"lvm\" init script is in the runlevels:" - ewarn "# rc-update add lvm boot" - ewarn - ewarn "Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want" - ewarn "to enable lvm autoactivation and metadata caching." + if [[ -z "${REPLACING_VERSIONS}" ]]; then + # This is a new installation + ewarn "Make sure the \"lvm\" init script is in the runlevels:" + ewarn "# rc-update add lvm boot" + ewarn + ewarn "Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want" + ewarn "to enable lvm autoactivation and metadata caching." + fi if use udev && [[ -d /run ]] ; then local permission_run_expected="drwxr-xr-x" diff --git a/sys-fs/lvm2/lvm2-2.03.10.ebuild b/sys-fs/lvm2/lvm2-2.03.10.ebuild index 66bf4be80bc6..c1a7dbc3b20a 100644 --- a/sys-fs/lvm2/lvm2-2.03.10.ebuild +++ b/sys-fs/lvm2/lvm2-2.03.10.ebuild @@ -253,8 +253,14 @@ src_install() { } pkg_postinst() { - ewarn "Make sure the \"lvm\" init script is in the runlevels:" - ewarn "# rc-update add lvm boot" + if [[ -z "${REPLACING_VERSIONS}" ]]; then + # This is a new installation + ewarn "Make sure the \"lvm\" init script is in the runlevels:" + ewarn "# rc-update add lvm boot" + ewarn + ewarn "Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want" + ewarn "to enable lvm autoactivation and metadata caching." + fi if use udev && [[ -d /run ]] ; then local permission_run_expected="drwxr-xr-x" -- cgit v1.2.3-65-gdbad