pinned: make it easy to use pinned packages

It appears the pinned attrset is a bit adhoc. This generalizes
pinned.nix so that you can do:

  $ nix build -f . pinned.stable.hwi
  $ nix build -f . pinned.unstable.hwi

etc

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin 2020-04-22 14:53:06 -07:00
parent 39ff39eb32
commit 47b2b110cc

View File

@ -1,13 +1,18 @@
let
nixpkgsPinned = import ./nixpkgs-pinned.nix;
unstable = import nixpkgsPinned.nixpkgs-unstable { config = {}; overlays = []; };
nixBitcoinPkgsUnstable = import ./. { pkgs = unstable; };
nixpkgsStable = import nixpkgsPinned.nixpkgs { config = {}; overlays = []; };
nixpkgsUnstable = import nixpkgsPinned.nixpkgs-unstable { config = {}; overlays = []; };
nixBitcoinPkgsStable = import ./. { pkgs = nixpkgsStable; };
nixBitcoinPkgsUnstable = import ./. { pkgs = nixpkgsUnstable; };
in
{
inherit (unstable)
inherit (nixpkgsUnstable)
bitcoin
bitcoind
clightning
lnd;
inherit (nixBitcoinPkgsUnstable) electrs;
stable = nixBitcoinPkgsStable;
unstable = nixBitcoinPkgsUnstable;
}