Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-portage-dev
Navigation:
Lists: gentoo-portage-dev: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-portage-dev@g.o
From: Brian Harring <ferringb@g.o>
Subject: Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
Date: Fri, 18 Nov 2005 10:14:10 -0600
Zac Medico wrote:
> Brian Harring wrote:
> >This makes portage go looking in two different locations for 
> >overrides; I know from looking through the code, 
> >/etc/portage/package.* overrides the includes, but users won't.
>
> This behavior could be documented and possibly configurable.
Adding another configurable to control it gets back to my point- 
should be a simple, extensible *singular* method of doing this, not N 
methods.


> >Configuration in two seperate locations of the same thing is usually a 
> >bad idea (exempting global configuration, user configuration, which 
> >this is not).  It's not intuitive, mainly.
> 
> The idea behind my patch was something akin to /etc/env.d, where 
> it's easy to yank things in and out in groups.  That makes it easy 
> for tools (unmasking and what else?) to make "transactional" 
> changes, in a sense.
Not so much transactional as groupping/seperation of each apps files. 
(sort of).

The type of changes you're talking about could just as easily be 
integrated into package.* with source command added to it.

Where's the gain in adding a secondary location for these files, when 
the same can be managed from the existing with a minor tweak?

> >>Index: pym/portage_util.py
> >>===================================================================
> >>--- pym/portage_util.py	(revision 2314)
> >>+++ pym/portage_util.py	(working copy)
> >>@@ -463,3 +463,12 @@
> >>		writemsg(line, noiselevel=1)
> >>	writemsg("Please file a bug for %s\n" % sys.argv[0], noiselevel=1)
> >>	writemsg("====================================\n\n", noiselevel=1)
> >>+
> >>+def subdir_paths(parent):
> >>+	full_paths=[]
> >>+	if os.path.exists(parent) and os.path.isdir(parent):

Two stats when os.path.isdir(parent) would suffice (single stat)

> >>+		for x in os.listdir(parent):
> >>+			full_path=os.path.join(parent,x)
> >>+			if os.path.isdir(full_path):
> >>+				full_paths.append(full_path)
> >>+	return full_paths
<snip>
> Good points.  I have to admit that I did not put much thought into that 
> function.  Like Jason said, the paths should be sorted.  It certainly needs 
> improvement. :)

Actually, in reading this through a bit closer, it won't go recursive- 
the code above will only go a single dir down, which isn't 
really friendly- either support recursing through subdirs or don't, 
basically. :)

~harring
Attachment:
pgpdMo683BlXy.pgp (PGP signature)
Replies:
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Zac Medico
References:
Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- capitalista
Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Zac Medico
Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Anthony Gorecki
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Marius Mauch
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Zac Medico
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Brian Harring
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
-- Zac Medico
Navigation:
Lists: gentoo-portage-dev: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
Next by thread:
Re: Re: Bugzilla Bug 112779: New and Improved Way to Handle /etc/portage
Previous by date:
Re: Making pax-utils a depend
Next by date:
Re: Making pax-utils a depend


Updated Jun 17, 2009

Summary: Archive of the gentoo-portage-dev mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.