aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gmail.com>2010-03-23 20:03:51 -0700
committerZac Medico <zmedico@gmail.com>2010-03-23 20:03:51 -0700
commitcd003fd10f92eed2a7f932d3be85935c321d1097 (patch)
tree3ff338f65d371b41ec7e2c3edd5c83072951027f /pym/portage/const.py
parentAdd check of herds in metadata.xml (diff)
downloadportage-cd003fd10f92eed2a7f932d3be85935c321d1097.tar.gz
portage-cd003fd10f92eed2a7f932d3be85935c321d1097.tar.bz2
portage-cd003fd10f92eed2a7f932d3be85935c321d1097.zip
Add support for PORTAGE_USERNAME and PORTAGE_GROUPNAME environment
variables. Thanks to Alec Warner <antarus@g.o> for submitting the initial PORTAGE_USERNAME patch from chromiumos-overlay.
Diffstat (limited to 'pym/portage/const.py')
-rw-r--r--pym/portage/const.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/pym/portage/const.py b/pym/portage/const.py
index 95ea76cb9..b017bcf75 100644
--- a/pym/portage/const.py
+++ b/pym/portage/const.py
@@ -66,6 +66,9 @@ BASH_BINARY = "/bin/bash"
MOVE_BINARY = "/bin/mv"
PRELINK_BINARY = "/usr/sbin/prelink"
+PORTAGE_GROUPNAME = os.environ.get("PORTAGE_GROUPNAME", 'portage')
+PORTAGE_USERNAME = os.environ.get("PORTAGE_USERNAME", 'portage')
+
INVALID_ENV_FILE = "/etc/spork/is/not/valid/profile.env"
REPO_NAME_FILE = "repo_name"
REPO_NAME_LOC = "profiles" + "/" + REPO_NAME_FILE