this post was submitted on 17 Nov 2023
1 points (100.0% liked)
Nix
1 readers
1 users here now
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
One can have a
shell.nixthat uses theflake.nixin a subdir. Here's how one can do this:in
shell.nix:in
./nix/flake.nix:Or whatever your flake is. Mostly important that we have
flake-compat.Then do a
nix flake updateand ensure thenix/flake.lockfile exists. At that pointnix-shell(in the repo root) will start working but will use thenix/flake.nixcontent, and only copy files innix/into the store. This does limit to some extent what the flake can do, but for manydevShelluses it's sufficient.