Gentoo Archives: gentoo-portage-dev

From: Jason Stubbs <jstubbs@g.o>
To: gentoo-portage-dev@l.g.o
Subject: Re: [gentoo-portage-dev] Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
Date: Fri, 18 Nov 2005 14:41:47
Message-Id: 200511182342.47429.jstubbs@gentoo.org
In Reply to: Re: [gentoo-portage-dev] Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage by Zac Medico
1 On Friday 18 November 2005 12:36, Zac Medico wrote:
2 > Marius Mauch wrote:
3 > > I think the point is more with a) temporary enabling/disabling of
4 > > sections and b) sharing sections. Having multiple files those situations
5 > > are a bit easier to handle.
6 > > Shouldn't be too hard offhand, basically
7 > > if isdir(foo):
8 > > for x in listdir(foo):
9 > > mylines.extend(grabfile(x))
10 > > else:
11 > > mylines = grabfile(foo)
12 >
13 > Okay, I wrote a small patch that handles everything supported by
14 > /etc/portage except bashrc (package.mask, package.unmask, package.keywords,
15 > package.use, mirrors, categories). I tested it by moving
16 > /etc/portage/package* into /etc/portage/includes/test/ and it seems to have
17 > behaved expectedly. Feedback is welcome and appreciated. ;)
18
19 I'd add a full_paths.sort() to subdir_paths() to ensure that 01-kde,
20 02-server, 03-whatever goes in the intended order but other than that it
21 looks like you've pretty much got it. :)
22
23 --
24 Jason Stubbs
25 --
26 gentoo-portage-dev@g.o mailing list