commit:     78925d7a2cdac37e74219558419b862d81e6a9c5
Author:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Sun Mar  3 05:44:12 2019 +0000
Commit:     Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Sun Mar  3 05:45:23 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=78925d7a

x11-apps/xinit: Only print postinst messages first time

Closes: https://bugs.gentoo.org/440454
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>

 x11-apps/xinit/xinit-1.4.0-r1.ebuild | 19 +++++++++++--------
 1 file changed, 11 insertions(+), 8 deletions(-)

diff --git a/x11-apps/xinit/xinit-1.4.0-r1.ebuild 
b/x11-apps/xinit/xinit-1.4.0-r1.ebuild
index a8b0150bc16..f8dedbb1ce7 100644
--- a/x11-apps/xinit/xinit-1.4.0-r1.ebuild
+++ b/x11-apps/xinit/xinit-1.4.0-r1.ebuild
@@ -56,12 +56,15 @@ src_install() {
 
 pkg_postinst() {
        xorg-2_pkg_postinst
-       ewarn "If you use startx to start X instead of a login manager like 
gdm/kdm,"
-       ewarn "you can set the XSESSION variable to anything in 
/etc/X11/Sessions/ or"
-       ewarn "any executable. When you run startx, it will run this as the 
login session."
-       ewarn "You can set this in a file in /etc/env.d/ for the entire system,"
-       ewarn "or set it per-user in ~/.bash_profile (or similar for other 
shells)."
-       ewarn "Here's an example of setting it for the whole system:"
-       ewarn "    echo XSESSION=\"Gnome\" > /etc/env.d/90xsession"
-       ewarn "    env-update && source /etc/profile"
+
+       if ! has_version 'x11-apps/xinit'; then
+               ewarn "If you use startx to start X instead of a login manager 
like gdm/kdm,"
+               ewarn "you can set the XSESSION variable to anything in 
/etc/X11/Sessions/ or"
+               ewarn "any executable. When you run startx, it will run this as 
the login session."
+               ewarn "You can set this in a file in /etc/env.d/ for the entire 
system,"
+               ewarn "or set it per-user in ~/.bash_profile (or similar for 
other shells)."
+               ewarn "Here's an example of setting it for the whole system:"
+               ewarn "    echo XSESSION=\"Gnome\" > /etc/env.d/90xsession"
+               ewarn "    env-update && source /etc/profile"
+       fi
 }

Reply via email to