Use nixFlakes in devShell

This commit is contained in:
Eelco Dolstra 2019-08-09 13:10:50 +02:00
parent a74dec6fb1
commit 1c9e22e73c
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
2 changed files with 31 additions and 24 deletions

View file

@ -1,6 +1,6 @@
{ {
"inputs": { "inputs": {
"nix": { "nix/ab16b3d076e9cd3ecfdcde128f43dd486b072557": {
"id": "nix", "id": "nix",
"inputs": { "inputs": {
"nixpkgs": { "nixpkgs": {
@ -11,9 +11,9 @@
"uri": "github:edolstra/nixpkgs/62ac6f7f504c8d3998558d9b269d22d26f13f1f0" "uri": "github:edolstra/nixpkgs/62ac6f7f504c8d3998558d9b269d22d26f13f1f0"
} }
}, },
"narHash": "sha256-MjLaMAh/KtAksnMwOH2GJn+YRJ4szwx24ybFXHTmShU=", "narHash": "sha256-I9YtUO9Ia5CwiTFo4QzSYdZHO2G+BQ7sM4MSq29NDqc=",
"nonFlakeInputs": {}, "nonFlakeInputs": {},
"uri": "github:NixOS/nix/5d8ec94d7fe4eded9f836bc49449d6eaff8fbc8f" "uri": "github:NixOS/nix/ab16b3d076e9cd3ecfdcde128f43dd486b072557"
}, },
"nixpkgs": { "nixpkgs": {
"id": "nixpkgs", "id": "nixpkgs",

View file

@ -5,16 +5,22 @@
epoch = 201906; epoch = 201906;
inputs = [ "nixpkgs" "nix" ]; inputs =
[ "nixpkgs"
"nix/ab16b3d076e9cd3ecfdcde128f43dd486b072557"
];
outputs = inputs: rec { outputs = inputs:
let
nix = inputs.nix.outputs.hydraJobs.build.x86_64-linux // {
perl-bindings = inputs.nix.outputs.hydraJobs.perlBindings.x86_64-linux;
};
in rec {
hydraJobs = import ./release.nix { hydraJobs = import ./release.nix {
hydraSrc = inputs.self; hydraSrc = inputs.self;
nixpkgs = inputs.nixpkgs; nixpkgs = inputs.nixpkgs;
nix = inputs.nix.outputs.hydraJobs.build.x86_64-linux // { inherit nix;
perl-bindings = inputs.nix.outputs.hydraJobs.perlBindings.x86_64-linux;
};
}; };
checks.build = hydraJobs.build.x86_64-linux; checks.build = hydraJobs.build.x86_64-linux;
@ -28,6 +34,7 @@
hydraSrc = inputs.self; hydraSrc = inputs.self;
nixpkgs = inputs.nixpkgs; nixpkgs = inputs.nixpkgs;
shell = true; shell = true;
inherit nix;
}).build.x86_64-linux; }).build.x86_64-linux;
}; };