[Nix-dev] Re: NixOS: Introduce sub-configurations
Nicolas Pierron
nicolas.b.pierron at gmail.com
Mon May 11 01:07:25 CEST 2009
Hi Ludovic,
On Sun, May 10, 2009 at 22:27, Ludovic Courtès <ludo at gnu.org> wrote:
>> Section 1 clarifies what I call an "instance".
> [...]
>
> FWIW, I find it misleading to use a common noun with a meaning different
> from that found in the dictionary.
Right, I thought about "instance" first because upstart-jobs, apache
are starting some-kind of instance for each option set.
>> - Documentation:
>
> [...]
>
> IIUC, this is the main issue you want to address: configuration options
> in NixOS are already stored in tree (nested attribute sets), but option
> documentation doesn't reflect this hierarchy.
>
> I agree that this is annoying, especially as the option set grows, as
> can be seen in the "List of Options" chapter
> (http://hydra.nixos.org/build/30778/download/1/manual.html#ch-options).
This is the primary goal of this modification because the existing
non-modularity limitation is not an issue yet.
> However, the term "sub-config" seems misleading to me. I would suggest
> something like "option category".
One point I remarked when coding it is that all NixOS configuration
can fit inside it. So at the end we could have something like
{
NixConfigs = [
firstComputerConfig
secondComputerConfig
];
}
Which is not highly important in our case. The name "sub-config" is
coming from this idea. But this is a bad naming for small sets. May
be "mkOptionSet" could be better, what do you think?
Thanks for your review,
--
Nicolas Pierron
http://www.linkedin.com/in/nicolasbpierron
- If you are doing something twice then you should try to do it once.
More information about the nix-dev
mailing list