Hello!
I have been struggling to find much documentation on this.
In the past, I have made extensive use of nix-shell shebangs like this:
#!/usr/bin/env nix-shell
#!nix-shell -I nixpkgs=[url]
#!nix-shell -i bash -p bash [deps]
I have several linting/release scripts following this pattern in a project which uses Flakes, and I would like to migrate them to nix shell.
Specifically, I would like these scripts to use the pinned version of Nixpkgs from the project’s flake.lock.
I tried --inputs-from ., but it didn’t work in combination with --no-use-registry, so I assume I must be doing this wrong.
Is there something I can use to
- Only allow pinned dependencies
- From a flake.{nix,lock} in the same directory?