Use locked nixpkgs version for nix-shell

This commit is contained in:
adisbladis 2022-01-08 08:53:26 +13:00
parent 985096e89d
commit 44655761c5

View file

@ -1,4 +1,15 @@
{ pkgs ? import <nixpkgs> { } { pkgs ? (
let
inherit (builtins) fromJSON readFile;
flakeLock = fromJSON (readFile ./flake.lock);
locked = flakeLock.nodes.nixpkgs.locked;
nixpkgs = assert locked.type == "github"; builtins.fetchTarball {
url = "https://github.com/${locked.owner}/${locked.repo}/archive/${locked.rev}.tar.gz";
sha256 = locked.narHash;
};
in
import nixpkgs { }
)
, srcDir ? null , srcDir ? null
}: }: