rycee changed the topic of #home-manager to: Support and discussion around the Home Manager project (https://github.com/rycee/home-manager) | Logs: https://logs.nix.samueldr.com/home-manager
liff has joined #home-manager
dom_ has joined #home-manager
dom_ has quit [Quit: Page closed]
kandinski has joined #home-manager
<kandinski> hi, I'm starting a new NixOS installation after a year or so or using Nix and NixOS, and I already have a question at point 2 of the installation instructions.
<kandinski> It says to add the master channel if I follow the master or unstable channel, and a 19.03 release if I follow a Nixpkgs version 19.03 channel. I always install stable on the system and then follow unstable on my /home/user. Does this mean I should follow https://github.com/rycee/home-manager/archive/master.tar.gz as well?
<rycee> kandinski: Yeah, I believe so. Basically, if `<nixpkgs>` for you points to Nixpkgs unstable then you should use HM master.
<kandinski> thanks, rycee
<rycee> Np :-)
<rycee> pie_: I had a look at the links a while ago but I didn't work on it any. offlinehacker made the nice PR using the http://kb.mozillazine.org/User.js_file technique. I don't know if he referenced this issue any.
<rycee> Hmm, I'm not certain what you meant by "convert a nested attribute set". You mean to use `profiles.default.settings`?
<pie_> not sure what you mean by profiles.default.settings, but this dotted stuff just reminds me strongly of configuration.nix settings
<rycee> Aha, right. Yeah, the option could have the type `attrs` but that is a bit tricky w.r.t merging.
<rycee> It would be great if there was a well-defined `recAttrsOf` type.
<rycee> Then we could have used `recAttrsOf (either bool (either int str)` for this.
<pie_> i was thinking just about the conversionto an output string side
<pie_> i havent done much with modules / types yet, but tha tmakes sense
<pie_> rycee, open an issue? xD
* pie_ too distracted with other things to think about this with any depth :v
* pie_ is also slow
<rycee> I believe this kind of type is part of rfc42: https://github.com/NixOS/rfcs/pull/42
<pie_> would be cool if you added a note that we have a use case for this (?)
<pie_> "all of the mozilla stuff" sounds at least somewhat significant to me#
<rycee> Well, there it is even more general, like `types.config.json`.
<pie_> sounds fine i guess. my initial thought is that the type checking and output generation are inevitable to separate
<pie_> so we're really talking about two things i think?
<pie_> nothing is stopping a possibly-foot-shooty "just serialize this attrset to a string"
<pie_> just some kind of simple recursive fold (which is what i say about a lot of "simple" algorithms and then collapse into a whimpering heap :P)
<rycee> pie_: Yeah, I'll add some more comments to this rfc. Will mention that as well.
* pie_ tries to draft up a simple implementation for the output
<pie_> rycee, though i guess its also a question how much of the configuration semantics we want to duplicate in nix heh...
<rycee> Ideally as little as possible, I would say :-)
<rycee> The way the Firefox settings option is now I guess is the minimal but I agree that it would be nice to allow a more structures recursive attributes approach, as long as we could offer sane merging.
<pie_> rycee, ok this does not look great but it seems to work https://bpaste.net/show/09ca91217670
<pie_> "\na.b=1\nb=2\nd=asd\ne.f.g=3"
<rycee> Yeah, something like that is what I would expect to support proper attribute sets for the firefox settings option.