Gentoo Archives: gentoo-portage-dev

From: Zac Medico <zmedico@g.o>
To: gentoo-portage-dev@l.g.o
Cc: Zac Medico <zmedico@g.o>
Subject: [gentoo-portage-dev] [PATCH] RepoConfigLoader: allow subsitution of variables like ROOT in repos.conf
Date: Fri, 23 Oct 2015 01:36:30
Message-Id: 1445564163-27294-1-git-send-email-zmedico@gentoo.org
In Reply to: Re: [gentoo-portage-dev] @sets and @profile does not work when ROOT=PORTAGE_CONFIGROOT=/my/new/root by Joakim Tjernlund
1 This makes it possible to sync repositories inside $ROOT.
2
3 X-Gentoo-Bug: 563836
4 X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=563836
5 ---
6 pym/portage/repository/config.py | 7 ++++++-
7 1 file changed, 6 insertions(+), 1 deletion(-)
8
9 diff --git a/pym/portage/repository/config.py b/pym/portage/repository/config.py
10 index a90a994..1060bc7 100644
11 --- a/pym/portage/repository/config.py
12 +++ b/pym/portage/repository/config.py
13 @@ -620,7 +620,12 @@ class RepoConfigLoader(object):
14 treemap = {}
15 ignored_map = {}
16 ignored_location_map = {}
17 - default_opts = {}
18 + default_opts = {
19 + "EPREFIX" : settings["EPREFIX"],
20 + "EROOT" : settings["EROOT"],
21 + "PORTAGE_CONFIGROOT" : settings["PORTAGE_CONFIGROOT"],
22 + "ROOT" : settings["ROOT"],
23 + }
24
25 if "PORTAGE_REPOSITORIES" in settings:
26 portdir = ""
27 --
28 2.4.9

Replies