1 |
Author: zmedico |
2 |
Date: 2008-11-21 23:21:51 +0000 (Fri, 21 Nov 2008) |
3 |
New Revision: 12023 |
4 |
|
5 |
Modified: |
6 |
main/branches/2.1.6/pym/_emerge/__init__.py |
7 |
Log: |
8 |
Bug #247776 - Show a warning message if CONFIG_PROTECT is empty. (trunk r12022) |
9 |
|
10 |
|
11 |
Modified: main/branches/2.1.6/pym/_emerge/__init__.py |
12 |
=================================================================== |
13 |
--- main/branches/2.1.6/pym/_emerge/__init__.py 2008-11-21 23:20:45 UTC (rev 12022) |
14 |
+++ main/branches/2.1.6/pym/_emerge/__init__.py 2008-11-21 23:21:51 UTC (rev 12023) |
15 |
@@ -13425,6 +13425,14 @@ |
16 |
|
17 |
return bool(missing_repo_names) |
18 |
|
19 |
+def config_protect_check(trees): |
20 |
+ for root, root_trees in trees.iteritems(): |
21 |
+ if not root_trees["root_config"].settings.get("CONFIG_PROTECT"): |
22 |
+ msg = "!!! CONFIG_PROTECT is empty" |
23 |
+ if root != "/": |
24 |
+ msg += " for '%s'" % root |
25 |
+ writemsg_level(msg, level=logging.WARN, noiselevel=-1) |
26 |
+ |
27 |
def ambiguous_package_name(arg, atoms, root_config, spinner, myopts): |
28 |
|
29 |
if "--quiet" in myopts: |
30 |
@@ -13508,6 +13516,7 @@ |
31 |
if "--quiet" not in myopts: |
32 |
portage.deprecated_profile_check() |
33 |
repo_name_check(trees) |
34 |
+ config_protect_check(trees) |
35 |
|
36 |
eclasses_overridden = {} |
37 |
for mytrees in trees.itervalues(): |