From 26e427aff7d247a730d3a6f1f573c9b048ed1c86 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Mon, 20 Oct 2014 13:04:28 -0700 Subject: [PATCH] emerge --read-news: prompt only if --ask X-Gentoo-Bug: 517310 X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=517310 --- man/emerge.1 | 5 +++-- pym/_emerge/actions.py | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/man/emerge.1 b/man/emerge.1 index 9873ba9..12e8b45 100644 --- a/man/emerge.1 +++ b/man/emerge.1 @@ -716,8 +716,9 @@ Disable the warning message that's shown prior to to be set in the \fBmake.conf\fR(5) \fBEMERGE_DEFAULT_OPTS\fR variable. .TP -.BR "\-\-read-news [ y | n ]" -Offer to read news via eselect if there are unread news. +.BR "\-\-read\-news [ y | n ]" +Offer to read news via eselect if there are unread news. This option +has no effect unless \fB\-\-ask\fR is enabled. .TP .BR "\-\-rebuild\-if\-new\-slot [ y | n ]" Automatically rebuild or reinstall packages when slot/sub\-slot := diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py index 4e8b83b..7672fe6 100644 --- a/pym/_emerge/actions.py +++ b/pym/_emerge/actions.py @@ -4064,6 +4064,7 @@ def run_action(emerge_config): uq = UserQuery(emerge_config.opts) if display_news_notification(emerge_config.target_config, emerge_config.opts) \ + and "--ask" in emerge_config.opt \ and "--read-news" in emerge_config.opts \ and uq.query("Would you like to read the news items while " \ "calculating dependencies?", -- 2.0.4