From: Fabian Groffen Date: Sat, 10 Dec 2011 12:12:17 +0000 (+0100) Subject: _get_global: fix up late night screwup X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=474d90ae979a40248362d5c4781b141f11acaac0;p=portage.git _get_global: fix up late night screwup --- diff --git a/pym/portage/data.py b/pym/portage/data.py index 196e5dc95..e25b545ea 100644 --- a/pym/portage/data.py +++ b/pym/portage/data.py @@ -155,10 +155,10 @@ def _get_global(k): v = env.get('PORTAGE_GRPNAME', PORTAGE_GROUPNAME) # END PREFIX LOCAL elif k == '_portage_uname': + env = getattr(portage, 'settings', os.environ) # PREFIX LOCAL: use var iso hardwired 'portage' - env = getattr(portage, 'settings', PORTAGE_USERNAME) + v = env.get('PORTAGE_USERNAME', PORTAGE_USERNAME) # END PREFIX LOCAL - v = env.get('PORTAGE_USERNAME', 'portage') else: raise AssertionError('unknown name: %s' % k)