Gentoo Archives: gentoo-commits

From: Zac Medico <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage:master commit in: pym/_emerge/
Date: Tue, 22 Feb 2011 02:41:09
Message-Id: f11ed8dc9f35d8d211173fd6f9a24091ed86d36b.zmedico@gentoo
1 commit: f11ed8dc9f35d8d211173fd6f9a24091ed86d36b
2 Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
3 AuthorDate: Tue Feb 22 02:38:45 2011 +0000
4 Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
5 CommitDate: Tue Feb 22 02:38:45 2011 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=f11ed8dc
7
8 chk_updated_cfg_files: fix plurality of message
9
10 This will fix bug #355803.
11
12 ---
13 pym/_emerge/actions.py | 10 ++++++++--
14 1 files changed, 8 insertions(+), 2 deletions(-)
15
16 diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py
17 index 08a92d6..980ad75 100644
18 --- a/pym/_emerge/actions.py
19 +++ b/pym/_emerge/actions.py
20 @@ -2944,9 +2944,15 @@ def chk_updated_cfg_files(eroot, config_protect):
21 for x in result:
22 print("\n"+colorize("WARN", " * IMPORTANT:"), end=' ')
23 if not x[1]: # it's a protected file
24 - print("config file '%s' needs updating." % x[0])
25 + writemsg_level("config file '%s' needs updating.\n" % x[0],
26 + level=logging.INFO, noiselevel=-1)
27 else: # it's a protected dir
28 - print("%d config files in '%s' need updating." % (len(x[1]), x[0]))
29 + if len(x[1]) == 1:
30 + writemsg_level("config file '%s' needs updating.\n" % x[1][0],
31 + level=logging.INFO, noiselevel=-1)
32 + else:
33 + writemsg_level("%d config files in '%s' need updating.\n" % \
34 + (len(x[1]), x[0]), level=logging.INFO, noiselevel=-1)
35
36 if result:
37 print(" "+yellow("*")+" See the "+colorize("INFORM","CONFIGURATION FILES")\