From 08ad6fb4697ec66df7306bb0c8674ea4bd0fccc3 Mon Sep 17 00:00:00 2001 From: Mats Rauhala Date: Sat, 1 Feb 2020 21:44:17 +0200 Subject: [PATCH] Pin to a specific version --- nixpkgs.json | 7 +++++++ release.nix | 11 ++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 nixpkgs.json diff --git a/nixpkgs.json b/nixpkgs.json new file mode 100644 index 0000000..0da9f04 --- /dev/null +++ b/nixpkgs.json @@ -0,0 +1,7 @@ +{ + "url": "https://github.com/NixOS/nixpkgs", + "rev": "7e1f60dfbba67b975d1a77d710a6f1437fd9709c", + "date": "2020-02-01T09:20:37-05:00", + "sha256": "0vk55459iljr5dzwnr5661l44b0wdc15952lk2rjcmxr1620yr5v", + "fetchSubmodules": false +} diff --git a/release.nix b/release.nix index 4157852..b129f5f 100644 --- a/release.nix +++ b/release.nix @@ -1,4 +1,13 @@ -{ pkgs ? import {} }: +let + pin = builtins.fromJSON (builtins.readFile ./nixpkgs.json); + pinnedPkgs = with pin; import (builtins.fetchTarball { + url = "https://github.com/NixOS/nixpkgs/archive/${rev}.tar.gz"; + inherit sha256; + }) {}; + +in + +{ pkgs ? pinnedPkgs }: let haskellPackages = pkgs.haskellPackages;