!SgYlXivkogarTVcnZO:nixos.org

Nix Flakes

901 Members
184 Servers

Load older messages


SenderMessageTime
30 Jan 2022
@edrex:matrix.orgedrexany examples of how to install a package from a flake in an included file (rather than in /etc/nixos/flake.nix itself)?20:54:05
@edrex:matrix.orgedrexoverlays? i haven't delved into that.20:54:34
@flyx:flyx.orgflyx
In reply to @edrex:matrix.org
any examples of how to install a package from a flake in an included file (rather than in /etc/nixos/flake.nix itself)?
you add it as input to the main flake file, then you can pass it as argument to the included file, or put it into your pkgs via overlay
23:06:54
31 Jan 2022
@mexisme:matrix.orgmexismeI've been using Flakes as a way to manage the install of multiple packages into my User account.21:26:05
@mexisme:matrix.orgmexismeit wasn't as intuitive to make it work as I expected, but I got it going, and it feels much cleaner than even Home Manager21:26:35
@mexisme:matrix.orgmexismei was wondering if anyone else is doing the same, and what libs, methods, tools, etc they were using?21:26:59
@mexisme:matrix.orgmexisme * it wasn't as intuitive to make it work as I expected (there were no clear docs, so I had to work it out) but I got it going, and it feels much cleaner than even Home Manager21:27:25
@teutat3s:pub.solarteutat3s mexisme: for an opinionated approach you could check out the devos template
https://github.com/divnix/devos
21:30:56
@teutat3s:pub.solarteutat3sbut it's for the whole system, not just user account21:31:12
@mexisme:matrix.orgmexismesure, i know how to leverage Flakes to install each user's own packages.21:33:03
@mexisme:matrix.orgmexisme but per-user makes it easier for that single user to manage + update their deps, and easier to use the same flakes.nix on a Mac 21:33:39
@mexisme:matrix.orgmexisme * sure, i know how to leverage Flakes to install each user's own packages from the main /etc/nixos/flake.nix 21:34:01
@mexisme:matrix.orgmexisme * but per-user makes it easier for that single user to manage + update their own deps, and easier to use the same flakes.nix on a Mac 21:34:14
@mexisme:matrix.orgmexisme * but per-user makes it easier for that single user to manage + update their own deps, and easier to use the same flake.nix on a Mac 21:34:24
@mexisme:matrix.orgmexisme oh, but should've said (first) that a consolidated project like that is very cool, teutat3s !
(sorry for jumping on the other-side, first)
21:36:35
@mexisme:matrix.orgmexisme it looks like a really nice way to organise a system flake.nix for one thing 21:37:50
1 Feb 2022
@enzime:nixos.devEnzime
In reply to @mexisme:matrix.org
it wasn't as intuitive to make it work as I expected (there were no clear docs, so I had to work it out) but I got it going, and it feels much cleaner than even Home Manager
I think that flakes aren't a replacement for home-manager, I use them together for maximum benefit
02:47:21
@enzime:nixos.devEnzimehttps://github.com/gytis-ivaskevicius/flake-utils-plus/blob/master/lib/options.nix this NixOS module is one of my favourite of all time02:47:43
@enzime:nixos.devEnzime if you pass it inputs, it'll pin <nixpkgs> and flake:nixpkgs to inputs.nixpkgs from your system config 02:48:43
@mexisme:matrix.orgmexisme
In reply to @enzime:nixos.dev
I think that flakes aren't a replacement for home-manager, I use them together for maximum benefit

I thought that would be the case, too, except I found Flakes quite a lot easier to use than Home Manager.

Esp. when an update is nix profile upgrade '.*' -L

04:42:30
@mexisme:matrix.orgmexisme
In reply to @enzime:nixos.dev
https://github.com/gytis-ivaskevicius/flake-utils-plus/blob/master/lib/options.nix this NixOS module is one of my favourite of all time
yeah, I found that today!
i have to read more about it after work, as it might replace a few of my custom functions!
04:43:37
@enzime:nixos.devEnzime
In reply to @mexisme:matrix.org

I thought that would be the case, too, except I found Flakes quite a lot easier to use than Home Manager.

Esp. when an update is nix profile upgrade '.*' -L

https://github.com/nix-community/home-manager#nix-flakes
04:43:52
@enzime:nixos.devEnzime you can use home-manager as a NixOS module 04:44:00
@enzime:nixos.devEnzimeit means that whenever you change either config you get a new generation04:44:53
@mexisme:matrix.orgmexismein the system config, yes? for my use-case, keeping per-user package installs out of the system config is useful.04:45:05
@mexisme:matrix.orgmexismeand `nix profile` being more-aware of flake metadata is extremely helpful04:45:43
@enzime:nixos.devEnzimeyeah if you're using it as a NixOS module it'd be at the system config level04:46:41
@enzime:nixos.devEnzime
In reply to @mexisme:matrix.org
in the system config, yes?
for my use-case, keeping per-user package installs out of the system config is useful.
what's your use case?
04:49:00
@mexisme:matrix.orgmexismeallowing users to independently specify their own packages on a single machine. similarly, but for MacOS, where I can't use NixDarwin.04:51:47
@mexisme:matrix.orgmexisme* - allowing users to independently specify their own packages on a single machine. - similarly, but for MacOS, where I can't use NixDarwin.04:51:59

There are no newer messages yet.


Back to Room ListRoom Version: 6